Ensure loading all apps once in ManageApplications

Some pages that extend ManageApplications always display a loading
spinner when entering them. This is caused by that it takes over
100 ms to load all apps and to sort the apps. In addition, the task of
loading all apps might be invoked twice, which caused loading time
increasing.

This CL is to make sure the task of loading all apps execute only once
in those pages that extend ManageApplications.

Bug: 222985623
Test: manual test
Change-Id: I3b15bf2eee2a4c220f42da39a29f0014cc620898
This commit is contained in:
Mill Chen
2022-05-04 17:51:10 +08:00
parent 261936eccf
commit fdbf748dc0
6 changed files with 19 additions and 8 deletions

View File

@@ -1176,7 +1176,7 @@ public class ManageApplications extends InstrumentedFragment
mSession.onResume();
mLastSortMode = sort;
if (mExtraInfoBridge != null) {
mExtraInfoBridge.resume();
mExtraInfoBridge.resume(false /* forceLoadAllApps */);
}
rebuild();
} else {