"If your app targets Android 12, you must specify the mutability of each PendingIntent object that your app creates. This additional requirement improves your app's security."
FLAG_IMMUTABLE was added in API 23 so that's why I'm using "> API 23". Using API 30 would also fix the Android 12 issue. Alternatively if PendingIntents should be mutable you could change it to "FLAG_MUTABLE".
It's already set with ANativeWindow_setGeometry, and eventually set/changed also by eglCreateWindowSurface.
- avoid issues with older device where SurfaceView cycle create/changed/destroy appears broken:
calling create/changed/changed, and leading to "deuqueBuffer failed at server side, error: -19", with black screen.
- re-read the format after egl window surface is created, to report the correct one (sometimes, changed from RGBA8888 to RGB24)
This could fix a rare crash if:
- onConfigurationChanged is called before onCreate();
or
shared libraries failed to load and onConfigurationChanged() is called
"In the second half of 2021, new apps will be required to publish with the Android App Bundle on Google Play"
(see https://developer.android.com/guide/app-bundle)
And "Android App Bundles don't support APK expansion (*.obb) files".
Improve handling of landscape/portrait orientation. Promote to SCREEN_ORIENTATION_SENSOR_* when needed.
Android window can be somehow resizable.
If SDL_WINDOW_RESIZABLE is set, window size change is allowed, for instance when orientation changes (provided the hint allows it).
Rare exception, not catch-able, which appears when the activity gets in a broken
state.
java.lang.IllegalStateException:
at android.app.FragmentManagerImpl.checkStateLoss (FragmentManagerImpl.java:1323)
at android.app.FragmentManagerImpl.popBackStackImmediate (FragmentManagerImpl.java:493)
at android.app.Activity.onBackPressed (Activity.java:2215)
at org.libsdl.app.SDLActivity.onBackPressed (SDLActivity.java)
at android.app.Activity.onKeyUp (Activity.java:2193)
at android.view.KeyEvent.dispatch (KeyEvent.java:2685)
at android.app.Activity.dispatchKeyEvent (Activity.java:2423)
at org.libsdl.app.SDLActivity.dispatchKeyEvent (SDLActivity.java)