fixed bug 500
[org.ibex.core.git] / src / org / ibex / core / Box.java
index f333abb..c34948d 100644 (file)
@@ -143,8 +143,8 @@ public final class Box extends JSScope implements Task {
     public void perform() throws JSExn {
         if (texture == null) { Log.warn(Box.class, "perform() called with null texture"); return; }
         if (texture.isLoaded) {
-            setWidth(max(texture.width, maxwidth), maxwidth); 
-            setHeight(max(texture.height, maxheight), maxheight); 
+            setWidth(max(texture.width, minwidth), maxwidth); 
+            setHeight(max(texture.height, minheight), maxheight); 
             DIRTY; }
         else { JS res = texture.stream; texture = null; throw new JSExn("image not found: "+res.unclone()); }
     }
@@ -848,7 +848,7 @@ public final class Box extends JSScope implements Task {
         b.clear(MOUSEINSIDE);
         deleteNode(i);
         b.parent = null;
-        RECONSTRAIN();
+        REPACK();
         putAndTriggerTrapsAndCatchExceptions("ChildChange", b);
     }
     
@@ -901,8 +901,8 @@ public final class Box extends JSScope implements Task {
             b.parent = this;
             
             // need both of these in case child was already uncalc'ed
-            b.RECONSTRAIN();
-            RECONSTRAIN();
+            b.REPACK();
+            REPACK();
             
             b.DIRTY; 
             putAndTriggerTrapsAndCatchExceptions("ChildChange", b);