aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2012-05-13 19:55:44 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2012-05-13 19:55:44 -0300
commit71931e2ef1cd028654537b6b9ed8f9cfc8bc54f5 (patch)
tree0f32cefd86564ecbc8a62647e8c6e153039ebf46 /actionpack/lib
parent2ef29ef9af8634999b8b615ef1643ab630bc59d8 (diff)
downloadrails-71931e2ef1cd028654537b6b9ed8f9cfc8bc54f5.tar.gz
rails-71931e2ef1cd028654537b6b9ed8f9cfc8bc54f5.tar.bz2
rails-71931e2ef1cd028654537b6b9ed8f9cfc8bc54f5.zip
Remove `:mouseover` option from `image_tag` helper.
Diffstat (limited to 'actionpack/lib')
-rw-r--r--actionpack/lib/action_view/helpers/asset_tag_helper.rb12
1 files changed, 0 insertions, 12 deletions
diff --git a/actionpack/lib/action_view/helpers/asset_tag_helper.rb b/actionpack/lib/action_view/helpers/asset_tag_helper.rb
index 3ba135d3d5..8368ebfbca 100644
--- a/actionpack/lib/action_view/helpers/asset_tag_helper.rb
+++ b/actionpack/lib/action_view/helpers/asset_tag_helper.rb
@@ -363,9 +363,6 @@ module ActionView
# * <tt>:size</tt> - Supplied as "{Width}x{Height}", so "30x45" becomes
# width="30" and height="45". <tt>:size</tt> will be ignored if the
# value is not in the correct format.
- # * <tt>:mouseover</tt> - Set an alternate image to be used when the onmouseover
- # event is fired, and sets the original image to be replaced onmouseout.
- # This can be used to implement an easy image toggle that fires on onmouseover.
#
# ==== Examples
# image_tag("icon") # =>
@@ -380,10 +377,6 @@ module ActionView
# <img alt="Icon" height="32" src="/icons/icon.gif" width="32" />
# image_tag("/icons/icon.gif", :class => "menu_icon") # =>
# <img alt="Icon" class="menu_icon" src="/icons/icon.gif" />
- # image_tag("mouse.png", :mouseover => "/assets/mouse_over.png") # =>
- # <img src="/assets/mouse.png" onmouseover="this.src='/assets/mouse_over.png'" onmouseout="this.src='/assets/mouse.png'" alt="Mouse" />
- # image_tag("mouse.png", :mouseover => image_path("mouse_over.png")) # =>
- # <img src="/assets/mouse.png" onmouseover="this.src='/assets/mouse_over.png'" onmouseout="this.src='/assets/mouse.png'" alt="Mouse" />
def image_tag(source, options={})
options = options.symbolize_keys
@@ -397,11 +390,6 @@ module ActionView
options[:width], options[:height] = size.split("x") if size =~ %r{^\d+x\d+$}
end
- if mouseover = options.delete(:mouseover)
- options[:onmouseover] = "this.src='#{path_to_image(mouseover)}'"
- options[:onmouseout] = "this.src='#{src}'"
- end
-
tag("img", options)
end