Note this problem also occurs with the sample browser.
I want my (Android) app to be Landscape only, so in the manifest.xml I set it to be Landscape:
Code: Select all
<activity android:name="android.app.NativeActivity"
android:label="OgreSampleBrowser"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="landscape"
android:theme="@android:style/Theme.NoTitleBar.Fullscreen">
<!-- Tell NativeActivity the name of or .so -->
<meta-data android:name="android.app.lib_name" android:value="OgreSampleBrowser" />
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
APP_CMD_SAVE_STATE
(a small wait...)
APP_CMD_TERM_WINDOW
and term_window restarts the app!
If I disable the landscape / no status bar (both cause the problem I think) then I get the following states:
APP_CMD_SAVE_STATE
(a small wait...)
APP_CMD_LOST_FOCUS
which is fine and dandy.
So, I want the app to have no status bar and be landscape, but it causes the app to restart on sleep?
Any ideas how this problem could be solved?