embedding Krpano in Flex : issue with embeddedstartup function call

  • Hi,

    It seems that if embeddedstartup is called too soon KRPano won't load in a Flex App. Here is what I'm doing :
    - step 1 : loading krpano.swf in a Loader (using URLRequest)
    - step 2 : adding the loader to a container (a UIComponent based class in my case)
    - step 3 : when receiving the complete event from the Loader.contentLoaderInfo, I call the embeddedstartup
    - step 4 : when KRPano call the krpano_ready method, I dispatch an event to signal that krpano is ready to be used

    My problem : this works perfectly well in debug mode. in runtime mode, 9 times out of 10 kr pano doesn't load at all. From what I can guess, il I call embeddedstartup before the krpano plugins are loaded, it fails (but doesn't give any error). If I wait half of a second between the complete event and the call to embeddedstartup it works!

    The qestion could be adressed to klaus directly : is there a way to solve this issue?

    Thanks,

    Laurent.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!