1 Reply Latest reply on Nov 10, 2010 10:11 AM by chiedozi

    MobileApplication questions

    feelthedarkness

      I've been testing with MobileApplication and so far it seems really nice. A few techniques I'm stuck on as far as the best way to do them with the mobile structure.

       

      1. What would be the best way to add a modal view on top of the ViewNavigator? For instance, if want to show an animated splash screen, it shouldn't be part of the ViewNavigator (I see thatMobileApplication has a splash screen property but it only takes an image ). There are also a bunch of other views that have a similar use case. Should I just push the view to the navigator without animating it whenever I need to show it or use PopUpManager? I read somewhere though that the mx.* package isn't optimized for mobile yet though...

       

      2. The stage.width and stage.height properties seem to change depending on how wide or high my content is. Is there a different way to access these values in mobile?

       

      /Kris

        • 1. Re: MobileApplication questions
          chiedozi Level 1

          1. It is okay to use the PopUpManager to show a modal view.  It's true that the mx package isn't necessarily optimized for mobile, but as long as you are using spark components that have mobile skins, things should be okay. 

           

          2. You should be using stage.stageWidth and stage.stageHeight to access the dimensions of the stage.

           

          Now about showing splash screens.  MobileApplication has a splashScreen property that allows you to show an image when the application starts up.  This will guarantee that the image will become visible as soon as the player allows.  Showing animated splash screens during application startup will be hard because the application's thread is being used to create and initialize the application, thus blocking the animation thread. You can show an animation as part of your initial view after applicationComplete, but that defeats some of the purpose of a splash screen.

           

          Chiedo