How to set the correct orientation of status bar with Flex-Air application on iOS 8+ while changing aspect ratio
<p>I have an application which supports both aspect ratio i.e LANDSCAPE and PORTRAIT. For some of the screen I need to set the orientation to PORTRAIT ONLY. To achieve this I have used :</p>

<p><strong><code>stage.setAspectRatio(StageAspectRatio.PORTRAIT);</code></strong></p>

<p>This change the orientation of application to portrait correctly and lock the orientation in portrait mode and is working correctly as per the requirement. Now when this code is used though application's aspect ratio is changed to portrait, but status bar orientation remain in LANDSCAPE mode.</p>

<p>Due to this when softkeyboard is opened it is opened in incorrect orientation. Please see image below:</p>

<p><a href="https://i.stack.imgur.com/cJQ8q.png" rel="nofollow noreferrer">Application behavior on ios 8+ after changing aspect ratio</a></p>

<p><a href="https://i.stack.imgur.com/cJQ8q.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cJQ8q.png" alt="enter image description here"></a>
Below is code from descriptor file :</p>

<pre><code>&lt;aspectRatio&gt;any&lt;/aspectRatio&gt;
&lt;renderMode&gt;auto&lt;/renderMode&gt;
&lt;autoOrients&gt;true&lt;/autoOrients&gt;
&lt;fullScreen&gt;true&lt;/fullScreen&gt;
&lt;visible&gt;true&lt;/visible&gt;
&lt;softKeyboardBehavior&gt;none&lt;/softKeyboardBehavior&gt;
</code></pre>

<p>This issue is not observed when running on ios version lower than 8. I am using flex 4.14.1 and AIR 19.0 version.</p>

<p>I had also tried setting the autoOrients to false in descriptor file and <code>stage.autoOrients = true</code> before changing the aspect ratio, but nothing has worked for me.</p>

<p>Any help on this will be great for me to proceed.</p>