简体   繁体   中英

UIInterfaceOrientation info.plist

I am working on an iOS app using Adobe Air to package it. I am trying to set the InterfaceOrientation to the info.plist.

So added UIInterfaceOrienation to my app.xml but it gives me "application.iPhone.InfoAdditions contains an invalid value" error when I try to create an iOS Package.

This is what the app.xml looks like

<iPhone>
    <InfoAdditions>
        <![CDATA[
                          ...... other values

                           <key>UIInterfaceOrientation</key>
                           <string>UIInterfaceOrientationLandscapeRight</string>

                ]]>
         </InfoAdditions>

Not too sure what I'm missing here. Any ideas?

I don't think you will be able to do this via the air packager.

The closest you will be able to get imho is this

portrait false

The solution you suggested will work in native development, but not (yet) using the air packager.

I think you are going to be able to change it via code like this: stage.setOrientation( StageOrientation.ROTATED_LEFT );

source : http://polygeek.com/4301_air-mobile_playing-with-stage-orientation-in-mobile-air-apps

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM