Synchronizing loader preload to avoid launcher getting stuck in loading state,
which could be caused by the following sequence of events
1) Starts preload => execution moved to background thread
a) check if loader is running
... execution moved to ui thread
2) Launcher starts
3) Cancels any running loader and starts a new loader
.... Execution on background thread
b) Cancels any running loader and starts a new loader
Synchronizing (3), and [a, b] under same lock would avoid this case
Bug: 73399920
Change-Id: I6b01f797fd6f4a2e5b3c078bb374ad40fcc311c8
2 files changed