flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Harui <aha...@adobe.com>
Subject Re: AW: Strange hanging when handling Popup
Date Wed, 26 Feb 2014 21:53:27 GMT
Can you try the 4.12 release candidate?  There was a bug in that
findHighestModalForm that I fixed for 4.12.

-Alex

On 2/26/14 1:08 PM, "Christofer Dutz" <christofer.dutz@c-ware.de> wrote:

>Ok ... so I sumbled over one PopupDialog in my application that didn't
>lock up and I had a look at the differences:
>
>Locking Up version is opened with this code:
>        // If the parent was not specified, use the root as parent.
>        if (!parent) {
>            var sm:ISystemManager =
>ISystemManager(FlexGlobals.topLevelApplication.systemManager);
>            // no types so no dependencies
>            var mp:Object =
>sm.getImplementation("mx.managers.IMarshallPlanSystemManager");
>            if (mp && mp.useSWFBridge()) {
>                parent = Sprite(sm.getSandboxRoot());
>            } else {
>                parent = Sprite(FlexGlobals.topLevelApplication);
>            }
>        }
>
>        // Open an center the popup.
>        PopUpManager.addPopUp(dialog, parent, true);
>        PopUpManager.centerPopUp(dialog);
>
>
>The non-locking version however uses this:
>
>        if (!displayParent) {
>            var sm:ISystemManager =
>ISystemManager(FlexGlobals.topLevelApplication.systemManager);
>            // no types so no dependencies
>            var mp:Object =
>sm.getImplementation("mx.managers.IMarshallPlanSystemManager");
>            if (mp && mp.useSWFBridge())
>                displayParent = Sprite(sm.getSandboxRoot());
>            else
>                displayParent = Sprite(FlexGlobals.topLevelApplication);
>        }
>
>        // Setting a module factory allows the correct embedded font to
>be found.
>        if (moduleFactory) {
>            this.moduleFactory = moduleFactory;
>        } else if (realParent is IFlexModule) {
>            this.moduleFactory = IFlexModule(realParent).moduleFactory;
>        } else {
>            if (realParent is IFlexModuleFactory) {
>                this.moduleFactory = IFlexModuleFactory(realParent);
>            } else {
>                this.moduleFactory =
>FlexGlobals.topLevelApplication.moduleFactory;
>            }
>
>            // also set document if parent isn't a UIComponent
>            if (!(parent is UIComponent)) {
>                this.document = FlexGlobals.topLevelApplication.document;
>            }
>        }
>
>        // Make the dialog center itself relative to the parent.
>        PopUpManager.addPopUp(this, displayParent, true, null,
>this.moduleFactory);
>        PopUpManager.centerPopUp(this);
>
>
>(Really wonder where I got that construct from )
>So it seems the moduleFactory setting seems to be preventing the lockup.
>The strange thing is that in my application
>I no longer have modules and I recall most moduleFactory issues were
>related to my module-loading.
>
>Anyway ... just thought I have that code indexed so mabe someone might
>find it usefull.
>
>Chris
>
>
>-----Urspr√ľngliche Nachricht-----
>Von: Christofer Dutz [mailto:christofer.dutz@c-ware.de]
>Gesendet: Mittwoch, 26. Februar 2014 21:11
>An: users@flex.apache.org
>Betreff: Strange hanging when handling Popup
>
>Hi,
>
>I just encountered a problem in one of my applications. I am using Flex
>4.11.0.20131017
>
>The popup opens, but when I click anywhere inside the popup, the
>application locks up causing a timeout error after a few seconds.
>
>This is what's logged to the console:
>
>[Fault] exception, information=Error: Error #1502: A script has executed
>for longer than the default timeout period of 15 seconds.
>at 
>mx.managers.systemClasses::ActiveWindowManager/findHighestModalForm()[/Use
>rs/justinmclean/Documents/ApacheFlex4.11.0/frameworks/projects/framework/s
>rc/mx/managers/systemClasses/ActiveWindowManager.as:436]
>at 
>mx.managers.systemClasses::ActiveWindowManager/mouseDownHandler()[/Users/j
>ustinmclean/Documents/ApacheFlex4.11.0/frameworks/projects/framework/src/m
>x/managers/systemClasses/ActiveWindowManager.as:469]
>at flash.events::EventDispatcher/dispatchEventFunction()
>at flash.events::EventDispatcher/dispatchEvent()
>at 
>mx.managers::SystemManager/mouseEventHandler()[/Users/justinmclean/Documen
>ts/ApacheFlex4.11.0/frameworks/projects/framework/src/mx/managers/SystemMa
>nager.as:2926]
>
>What could be causing this?
>
>Chris


Mime
View raw message