Activity restarts even though "configChanges" for activity is defined with "screenSize" in AndroidManifest.xml

Viewed 50

my application's activity is defined in AndroidManifest.xml as follows.

<activity
            android:name=".ui.activities.MainActivity"
            android:configChanges="orientation|screenSize"
            android:screenOrientation="sensor"
            android:windowSoftInputMode="adjustResize" />

The screenSize statement is attached, but when the screen rotation is changed on API 30 devices, the activity restarts and the onCreate method is debugged.

I don't want the activity to restart when the screen rotation changes for all devices.

Is there anyone who can help?

0 Answers
Related