Skip to main content
Participating Frequently
October 10, 2011
Question

Launch Screen in Landscape Mode

  • October 10, 2011
  • 13 replies
  • 1730 views

I have an app that is locked to landscape mode. I then put in a portrait oriented Default.png as this is an iPhone game (not iPad). The launch screen loads great but turns landscape (and of course looks stretched) for about half a second before the game screen shows. This of course will not pass inspection at Apple so hoping someone has some advice. thanks.

This topic has been closed for replies.

13 replies

October 18, 2011

Hi Dale,

Have you logged a bug against this issue yet? Can you please share a link to that?

Also, please share the project files or sample that can help us in reproducing the issue.

DaleATLAuthor
Participating Frequently
November 30, 2011

Sorry it took so long for me to put this together but here you go. Not sure this is a bug or just a misconfiguration on my part. Here are two links to help see what is going on. The first link is the exported project and the second one is a video so that you can see what is happening on my phone (as well as a reflection of my flip camera ). The app starts with the loader screen in portrait then switches to landscape just before the app loads (which distorts the image). I need the loading screen to stay in one orientation.

https://s3.amazonaws.com/DalePublic/TestLaunchScreenOnIPhone.fxp

https://s3.amazonaws.com/DalePublic/VID00003.MP4

Any help would be appreciated.

Inspiring
October 11, 2011

Dale, i have the same problem for one of my app published 3 weeks ago, in landscape mode

You have to set in the xml of your app:

<autoOrients>false</autoOrients>

and

<aspectRatio>landscape</aspectRatio>

Your app will start in landscape mode but if you don't anything else, Apple will reject your app because it simply doesn't support screen 180° rotation.

So after your app has started, just reput autoOrients to true, and use the orientation changed event.

protected function initMyapp(event:Event):void

{

stage.scaleMode = StageScaleMode.NO_SCALE;

stage.align = StageAlign.TOP_LEFT;

stage.autoOrients = true;

if(stage.orientation == StageOrientation.DEFAULT || stage.orientation == StageOrientation.UPSIDE_DOWN)

{

stage.setOrientation(StageOrientation.ROTATED_RIGHT);

}

stage.addEventListener(StageOrientationEvent.ORIENTATION_CHANGING,onOrientationChanging );

}

 

protected function onOrientationChanging(event:StageOrientationEvent):void

{

//keep portrait mode

if(event.afterOrientation == StageOrientation.DEFAULT || event.afterOrientation == StageOrientation.UPSIDE_DOWN ) event.preventDefault();

OR

//Keep landscape mode:

if(event.afterOrientation == StageOrientation.ROTATED_LEFT || event.afterOrientation == StageOrientation.ROTATED_RIGHT ) event.preventDefault();

}

Colin Holgate
Inspiring
October 11, 2011

What you are talking about is a different topic. It turns out that I too have the symptoms on one app, where the portrait splash screen appears and then rotates around to show a half screen version of itself, even though autoorients is turned on.

The thing you're talking about would only be rejected on iPad, and in Dale's case it's iPod/iPhone, and Apple don't seem to mind if those are fixed to one landscape.

DaleATLAuthor
Participating Frequently
October 11, 2011

Here is where I am for now.

If I use the splashScreenImage property on the ViewNavigatorApplication then I get the strange last second rotation behavior on the launch image.

If I just name the file Default.png and put it in the root then I get a different behavior where I get a blank screen for that same amount of time right before the app loads instead of the rotated image.

Make sense?

For now, I am fine with the blank screen before it loads but will still work on submitting this issue to Adobe. Looks like there could be a bug in one or both of these methods.

Colin Holgate
Inspiring
October 10, 2011

In the publishing settings there is an aspect ratio drop down menu. Try setting that to Portrait.

DaleATLAuthor
Participating Frequently
October 10, 2011

Wouldn't that change the app to Portrait. I need the application locked to landscape mode. I just need the loading screen to show one way OR the other, not both.

Colin Holgate
Inspiring
October 10, 2011

Sorry, misread part of that. The answer is easy then (I hope!), set it to landscape, turn off autoOrients, and make your Default.png image look like a landscape design on its side. That is, it would be 320x480 (also include a 640x960 image named Default@2x.png for Retina display), and would be your 480x320 splash screen design on its side (rotated 90 degrees clockwise).