Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-22852

Adding a non-visible popup to a loaded swf using swfBridge, throws an error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Adobe Flex SDK 3.2 (Release)
    • None
    • mx: General
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Even though following information is for the 3.2.0 SDK I have also confirmed that the bug still exists in 3.5.0

      Steps to reproduce:
      1. Load a swf into another swf in such a way that sm.useSwfBridge(); Would Return true
      2. Create a PopUp, set visible = false, then add PopUp Using PopUpManager.

      Actual Results:
      Popup Gets added, but since there is a check in PopUpManagerImp that requests the popup to be added again when swfBridge is being used, it attempts to load again with no parent set. The particular bit of code that checks to see if the window is visible fails to make sure that there is a window first, so the following gets thrown:
      TypeError: Error #1009: Cannot access a property or method of a null object reference.
      at mx.managers::PopUpManagerImpl/createModalWindow()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers\PopUpManagerImpl.as:721]
      at mx.managers::PopUpManagerImpl/createModalWindowRequestHandler()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers\PopUpManagerImpl.as:1248]
      at flash.events::EventDispatcher/dispatchEventFunction()
      at flash.events::EventDispatcher/dispatchEvent()

      Expected Results:
      That the popup will be added to popupmanager and display on screen without a runtime error

      Workaround (if any):
      Put addPopup in a try catch block.
      Simply setting PopUp.visible = true does not fully resove the issue, and causes a problem further down the line:
      TypeError: Error #1034: Type Coercion failed: cannot convert Object@17b2c971 to flash.geom.Rectangle.
      at mx.managers::PopUpManagerImpl/showModalWindowRequest()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers\PopUpManagerImpl.as:1272]
      at flash.events::EventDispatcher/dispatchEventFunction()
      at flash.events::EventDispatcher/dispatchEvent()
      at mx.managers::SystemManager/modalWindowRequestHandler()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: