From 1def3f0073d94564ab46a02a6c567a6c091a4e96 Mon Sep 17 00:00:00 2001 From: Jeremy Kemper Date: Tue, 13 Mar 2007 05:24:10 +0000 Subject: Deprecation: remove deprecated update_element_function, start_form_tag, and end_form_tag. Use RJS and form_tag instead. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6409 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- .../lib/action_view/helpers/deprecated_helper.rb | 34 ---------------------- 1 file changed, 34 deletions(-) delete mode 100644 actionpack/lib/action_view/helpers/deprecated_helper.rb (limited to 'actionpack/lib/action_view/helpers/deprecated_helper.rb') diff --git a/actionpack/lib/action_view/helpers/deprecated_helper.rb b/actionpack/lib/action_view/helpers/deprecated_helper.rb deleted file mode 100644 index 04392f5b04..0000000000 --- a/actionpack/lib/action_view/helpers/deprecated_helper.rb +++ /dev/null @@ -1,34 +0,0 @@ -module ActionView - module Helpers - module PrototypeHelper - - def update_element_function(element_id, options = {}, &block) - content = escape_javascript(options[:content] || '') - content = escape_javascript(capture(&block)) if block - - javascript_function = case (options[:action] || :update) - when :update - if options[:position] - "new Insertion.#{options[:position].to_s.camelize}('#{element_id}','#{content}')" - else - "$('#{element_id}').innerHTML = '#{content}'" - end - - when :empty - "$('#{element_id}').innerHTML = ''" - - when :remove - "Element.remove('#{element_id}')" - - else - raise ArgumentError, "Invalid action, choose one of :update, :remove, :empty" - end - - javascript_function << ";\n" - options[:binding] ? concat(javascript_function, options[:binding]) : javascript_function - end - deprecate :update_element_function => "use RJS instead" - - end - end -end \ No newline at end of file -- cgit v1.2.3