[Android] LaunchMode.SingleTask in MainActivity causes blank UI on relaunch (Uno 5.4 regression) #18325
Labels
kind/bug
Something isn't working
kind/regression
Something was working, now it isn't
platform/android 🤖
Categorizes an issue or PR as relevant to the Android platform
project/navigation-lifecycle 🧬
Categorizes an issue or PR as relevant to the navigation and lifecycle (NavigationView, AppBar, ...)
Current behavior
Starting with 5.4.x, when
MainActivity
is set toLaunchMode.SingleTask
, the app shows a blank UI if it is running persistently in the background (i.e. because it is receiving background location updates) and it is closed/swiped away and then relaunched:Screen_Recording_20240927_134515_Volt.mp4
Expected behavior
Same as version <= 5.3.x - app UI should restore to its previous state and show properly again after relaunch:
Screen_Recording_20240927_133913_Volt.mp4
How to reproduce it (as minimally and precisely as possible)
Then run something that will keep the activity alive like a background service or background location updates, swipe away the app, then click the icon to launch it again and reactivate the activity and notice you get a blank screen.
Repro project would require large amounts of actual app code that contains all the permission request logic/UI, background location update service, etc...so if you want that then I will need to send the code privately as I can't share it publicly.
Workaround
None
Works on UWP/WinUI
None
Environment
No response
NuGet package version(s)
5.4.5, 5.5.0-dev-66
Affected platforms
Android
IDE
No response
IDE version
No response
Relevant plugins
No response
Anything else we need to know?
No response
The text was updated successfully, but these errors were encountered: