From 51cf6b65bec7c91b21172fff6224855f503e01fa Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Fri, 8 Aug 2008 03:46:11 +0000 Subject: [PATCH] Make this optional, and not the default. Turns out a bunch of shit makes the wrapper size a little bigger, and some things seem to freak out when the wrapper has a size, even when includeInLayout=false. Flex you very much. git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@616 ed5b42cb-e716-0410-a449-f6a68f950b19 --- src/as/com/threerings/flex/FlexWrapper.as | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/as/com/threerings/flex/FlexWrapper.as b/src/as/com/threerings/flex/FlexWrapper.as index 411ae4e5..edb96ce8 100644 --- a/src/as/com/threerings/flex/FlexWrapper.as +++ b/src/as/com/threerings/flex/FlexWrapper.as @@ -30,13 +30,15 @@ import mx.core.UIComponent; */ public class FlexWrapper extends UIComponent { - public function FlexWrapper (object :DisplayObject) + public function FlexWrapper (object :DisplayObject, inheritSize :Boolean = false) { // don't capture mouse events in this wrapper mouseEnabled = false; addChild(object); - width = object.width; - height = object.height; + if (inheritSize) { + width = object.width; + height = object.height; + } } } }