[英]Android app terminates when screen orientation is changed
Please have a look at my .manifest ,although i have put 尽管我已经输入了,请看一下我的清单。
android:screenOrientation="sensor"
the moment i change my screen orientation the app will terminate (no crashing hence no log). 当我更改屏幕方向时,应用程序将终止(不会崩溃,因此也不会产生日志)。 I have read and added the below syntax 我已阅读并添加了以下语法
android:configChanges="orientation|screenSize|keyboardHidden"/>
but still no change. 但仍然没有变化。
have a look at my .manifest and suggest me how to resolve the issue (currently i have removed the android:configchanges part.) 看看我的.manifest并建议我如何解决此问题(当前我已删除android:configchanges部分。)
package="com.mystictreegames.pagecurl"
android:versionName="1.1" android:versionCode="2">
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="4"/>
<application android:icon="@drawable/icon" android:label="@string/app_name">
<activity
android:label="@string/app_name"
android:excludeFromRecents="true"
android:screenOrientation="sensor"
android:name="AndroidPageCurlActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:screenOrientation="sensor"
android:label="@string/standalone_example"
android:name="StandaloneExample"></activity>
</application>
</manifest>
尝试这个,
android:configChanges="orientation|keyboardHidden|screenSize|screenLayout"
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.