Created
September 8, 2011 17:31
-
-
Save jonalter/1204026 to your computer and use it in GitHub Desktop.
Android: app and splash screen orientation with TiSDK 1.7.2 (must use custom AndroidManifest.xml)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- add android:screenOrientation="portrait" to the main activity --> | |
| <!-- This sets the splash screen --> | |
| <activity android:name=".Test1Activity" android:screenOrientation="portrait" | |
| android:label="Test1" android:theme="@style/Theme.Titanium" | |
| android:configChanges="keyboardHidden|orientation"> | |
| <intent-filter> | |
| <action android:name="android.intent.action.MAIN" /> | |
| <category android:name="android.intent.category.LAUNCHER" /> | |
| </intent-filter> | |
| </activity> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var window = Ti.UI.createWindow({ | |
| backgroundColor : 'white', | |
| layout : 'vertical' | |
| }); | |
| // this sets the window | |
| window.orientationModes = [Ti.UI.PORTRAIT]; | |
| var button = Ti.UI.createButton({ | |
| title : 'test', | |
| width : 150, | |
| height : 60, | |
| top : 20 | |
| }); | |
| window.add(button); | |
| window.open(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment