Changeset 5150

Show
Ignore:
Timestamp:
08/06/08 12:10:27 (5 months ago)
Author:
matti.tahvonen@…
Message:

fixes #1926 (random layout issues with Safari + Splitpanel)

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/com/itmill/toolkit/terminal/gwt/client/ui/ISplitPanel.java

    r4591 r5150  
    286286    } 
    287287 
    288     public void setHeight(String height) { 
     288    public void setHeight(final String height) { 
    289289        super.setHeight(height); 
    290         // give sane height 
    291         getOffsetHeight(); // shake IE 
    292         if (getOffsetHeight() < MIN_SIZE) { 
    293             super.setHeight(MIN_SIZE + "px"); 
     290        if (isAttached()) { 
     291            // give sane height 
     292            getOffsetHeight(); // shake IE 
     293            if (getOffsetHeight() < MIN_SIZE) { 
     294                super.setHeight(MIN_SIZE + "px"); 
     295            } 
    294296        } 
    295297    } 
     
    297299    public void setWidth(String width) { 
    298300        super.setWidth(width); 
    299         // give sane width 
    300         getOffsetWidth(); // shake IE 
    301         if (getOffsetWidth() < MIN_SIZE) { 
    302             super.setWidth(MIN_SIZE + "px"); 
     301        if (isAttached()) { 
     302            // give sane width 
     303            getOffsetWidth(); // shake IE 
     304            if (getOffsetWidth() < MIN_SIZE) { 
     305                super.setWidth(MIN_SIZE + "px"); 
     306            } 
    303307        } 
    304308    }