summaryrefslogtreecommitdiff
path: root/config/initializers/form_improvements.rb
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2014-07-09 23:26:06 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2014-07-09 23:26:06 -0400
commitb15f0bd957dae0ae23140135b01506fbeca2a1e5 (patch)
treeb7940e92dad53cec0d039e25740de98378480849 /config/initializers/form_improvements.rb
parent05104c93a1b12845875691e7b97ea9d9239c8ef1 (diff)
mv config/initializers/{form_improvements,leaguer_firefox_submit_hack}.rb
Note: this is no longer required in Firefox 30.
Diffstat (limited to 'config/initializers/form_improvements.rb')
-rw-r--r--config/initializers/form_improvements.rb31
1 files changed, 0 insertions, 31 deletions
diff --git a/config/initializers/form_improvements.rb b/config/initializers/form_improvements.rb
deleted file mode 100644
index c91dce8..0000000
--- a/config/initializers/form_improvements.rb
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- ruby-indent-level: 2; indent-tabs-mode: nil -*-
-module ActionView
- module Helpers
- module FormTagHelper
-
- # This is modified from actionpack-4.0.2/lib/action_view/helpers/form_tag_helper.rb#submit_tag
- def submit_tag(value = "Save changes", options = {})
- options = options.stringify_keys
-
- if disable_with = options.delete("disable_with")
- message = ":disable_with option is deprecated and will be removed from Rails 4.1. " \
- "Use 'data: { disable_with: \'Text\' }' instead."
- ActiveSupport::Deprecation.warn message
-
- options["data-disable-with"] = disable_with
- end
-
- if confirm = options.delete("confirm")
- message = ":confirm option is deprecated and will be removed from Rails 4.1. " \
- "Use 'data: { confirm: \'Text\' }' instead'."
- ActiveSupport::Deprecation.warn message
-
- options["data-confirm"] = confirm
- end
-
- content_tag(:button, value, { "type" => "submit", "name" => "commit", "value" => value }.update(options))
- end
-
- end
- end
-end