From ef15149661bc25fa31d058ef0a5166326814b368 Mon Sep 17 00:00:00 2001 From: Jouni Koivuviita Date: Tue, 6 Oct 2009 12:44:43 +0000 Subject: Fixes #3405: Sampler button icons messed up in IE6 svn changeset:9108/svn branch:6.1 --- src/com/vaadin/terminal/gwt/client/Util.java | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/com/vaadin/terminal/gwt/client/Util.java b/src/com/vaadin/terminal/gwt/client/Util.java index 770214f45e..ab41de0b0c 100644 --- a/src/com/vaadin/terminal/gwt/client/Util.java +++ b/src/com/vaadin/terminal/gwt/client/Util.java @@ -230,14 +230,22 @@ public class Util { /*-{ el.attachEvent("onload", function() { var src = el.src; - if (src.indexOf(".png")<1) return; - var w = el.width||16; - var h = el.height||16; - el.src =blankImageUrl; - el.style.height = h+"px"; - el.style.width = w+"px"; - el.style.padding = "0px"; - el.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+src+"', sizingMethod='scale')"; + if (src.indexOf(".png") < 1) return; + var w = el.width || 16; + var h = el.height || 16; + if(h==30 || w==28) { + setTimeout(function(){ + el.style.height = el.height + "px"; + el.style.width = el.width + "px"; + el.src = blankImageUrl; + },10); + } else { + el.src = blankImageUrl; + el.style.height = h + "px"; + el.style.width = w + "px"; + } + el.style.padding = "0"; + el.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+src+"', sizingMethod='crop')"; },false); }-*/; -- cgit v1.2.3