I have my Xamarin.Forms app running on an Android device, then background it and open the 'Gesture Navigation' option in the device's settings app (System -> Gestures -> System navigation). Switching from 'Gesture navigation' to '3-button navigation' or vice-versa, then returning to my application is causing the OnDestroy method to be called main activity, and currently my app does not resume correctly, so ideally I'd like to stop the configuration change from calling OnDestroy and I will handle the configuration change.
I already have the activity set to handle the following configuration changes:-
ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.SmallestScreenSize | ConfigChanges.Orientation
And in the OnDestroy method I'm attempting to resolve what configuration change has caused the event be calling:-
if (this.mainActivity.IsChangingConfigurations)
LogService.Debug($"OnDestroy because of configuration change 0x{this.mainActivity.ChangingConfigurations:X}");
However the value returned from this.mainActivity.ChangingConfigurations is 0x80000000 which doesn't map to a ConfigChanges enum.
Does anyone know what configuration change is made when a Gesture navigation change is made, and how I can update my app to handle it without destroying the app?