Browse Source

fixes #2437, regression due changes in ICaption. Most likely visible in other places too, hopefully those are now fixed too.

svn changeset:6463/svn branch:trunk
tags/6.7.0.beta1
Matti Tahvonen 15 years ago
parent
commit
7cf525985a
1 changed files with 9 additions and 1 deletions
  1. 9
    1
      src/com/itmill/toolkit/terminal/gwt/client/ICaption.java

+ 9
- 1
src/com/itmill/toolkit/terminal/gwt/client/ICaption.java View File

@@ -229,7 +229,15 @@ public class ICaption extends HTML {
*/
iconOnloadHandled = true;

setMaxWidth(maxWidth);
// if max width defined, recalculate
if (maxWidth != -1) {
setMaxWidth(maxWidth);
} else {
String width = getElement().getStyle().getProperty("width");
if (width != null && !width.equals("")) {
setWidth(getRequiredWidth() + "px");
}
}

/*
* The size of the icon might affect the size of the component so we

Loading…
Cancel
Save