X-Git-Url: http://git.megacz.com/?p=org.ibex.core.git;a=blobdiff_plain;f=src%2Forg%2Fxwt%2FBox.java;h=8c36f81bd56f47a3657845347a1b12f35338c37c;hp=3da445a86b5ffecfddef6c40a5edac73739a1d69;hb=4bc540de0c5679607067b4598e99acee2cc66356;hpb=bc6ac951869686b84803f45f549ccb888a9f776c diff --git a/src/org/xwt/Box.java b/src/org/xwt/Box.java index 3da445a..8c36f81 100644 --- a/src/org/xwt/Box.java +++ b/src/org/xwt/Box.java @@ -461,8 +461,8 @@ public final class Box extends JSScope { case "redirect": if (redirect == this) redirect = (Box)value; else Log.log(this, "redirect can only be set once"); case "font": font = value == null ? null : Font.getFont((Res)value, font == null ? 10 : font.pointsize); MARK_RESIZE; dirty(); case "fontsize": font = Font.getFont(font == null ? null : font.res, toInt(value)); MARK_RESIZE; dirty(); - case "x": if (test(PACKED) && parent != null) return; CHECKSET_INT(x); dirty(); MARK_RESIZE; dirty(); - case "y": if (test(PACKED) && parent != null) return; CHECKSET_INT(y); dirty(); MARK_RESIZE; dirty(); + case "x": if (parent==null && Surface.fromBox(this)!=null) { CHECKSET_INT(x); } else { if (test(PACKED) && parent != null) return; CHECKSET_INT(x); dirty(); MARK_RESIZE; dirty(); } + case "y": if (parent==null && Surface.fromBox(this)!=null) { CHECKSET_INT(y); } else { if (test(PACKED) && parent != null) return; CHECKSET_INT(y); dirty(); MARK_RESIZE; dirty(); } case "KeyPressed": return; // prevent stuff from hitting the Hash case "KeyReleased": return; // prevent stuff from hitting the Hash case "PosChange": return; // prevent stuff from hitting the Hash