move when beads attached so that containerview can resize contentarea before layout
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/1f3429aa Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/1f3429aa Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/1f3429aa Branch: refs/heads/develop Commit: 1f3429aa39821c95249a7873c1a306b3e2a15a31 Parents: a3e7225 Author: Alex Harui <aha...@apache.org> Authored: Tue Jan 13 10:07:56 2015 -0800 Committer: Alex Harui <aha...@apache.org> Committed: Tue Jan 13 10:07:56 2015 -0800 ---------------------------------------------------------------------- .../org/apache/flex/html/beads/ContainerView.as | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1f3429aa/frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/ContainerView.as ---------------------------------------------------------------------- diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/ContainerView.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/ContainerView.as index d6b587b..9019315 100644 --- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/ContainerView.as +++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/ContainerView.as @@ -84,16 +84,6 @@ package org.apache.flex.html.beads var host:UIBase = value as UIBase; - if (_strand.getBeadByType(IBeadLayout) == null) - { - var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout"); - if (c) - { - var layout:IBeadLayout = new c() as IBeadLayout; - _strand.addBead(layout); - } - } - if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) { host.addEventListener("childrenAdded", changeHandler); @@ -109,6 +99,16 @@ package org.apache.flex.html.beads else checkActualParent(); } + + if (_strand.getBeadByType(IBeadLayout) == null) + { + var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout"); + if (c) + { + var layout:IBeadLayout = new c() as IBeadLayout; + _strand.addBead(layout); + } + } } private function checkActualParent():Boolean