My app needs to perform some view resizing after the layout is done. It's currently done in onWindowFocusChanged().
It's not working as intended on Windows 11 (using Windows Subsystem for Android, WSA). During manual window resizing, the Activity gets destroyed and recreated a few times, but:
onWindowFocusChanged()is never called during or after the resizing- the Activity is not recreated at the exact end of the resizing, so posting a runnable to the UI queue is not an option: the view's dimensions would still be wrong at this point.
I have noticed that toggling on the WSA compatibility setting Disable smooth resize actually solves the issue: nothing happens during the resizing, but onWindowFocusChanged() is called when the resizing is over.
Can I force this behavior programmatically?
I don't want users to be forced to change this setting to use the app normally.
