From b8315994b9dcc7e322c69498e51ed259418000b5 Mon Sep 17 00:00:00 2001 From: Mill Chen Date: Thu, 12 May 2022 22:44:34 +0800 Subject: [PATCH] Make sure loading extra info once In those pages that extend ManageApplications, they need to load extra information from other services as a summary for each package or as a condition to be filtered. The way to load extra information is invoked at two places. One is invoked once all apps are loaded and the other is running before all apps loaded. It took much more time to prepare the data for those pages if it is time consuming to load extra info. This also caused the loading spinner to be always shown. This change is to make sure that the loading extra info is invoked just once when entering those pages and to decrease the time to load extra info. The loading spinner is still displayed on some pages since it still needs to take more than 100 ms to load extra infor in those pages. Bug: 222441965 Bug: 223315960 Bug: 222981538 Bug: 222981533 Test: manual test Change-Id: I8d0084ab5c412d9661f31446e613b7d1f58202ca --- src/com/android/settings/applications/AppStateBaseBridge.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/com/android/settings/applications/AppStateBaseBridge.java b/src/com/android/settings/applications/AppStateBaseBridge.java index d7f253b6c0b..a4bdabf43e3 100644 --- a/src/com/android/settings/applications/AppStateBaseBridge.java +++ b/src/com/android/settings/applications/AppStateBaseBridge.java @@ -52,7 +52,6 @@ public abstract class AppStateBaseBridge implements ApplicationsState.Callbacks public void resume(boolean forceLoadAllApps) { mForceLoadAllApps = forceLoadAllApps; - mHandler.sendEmptyMessage(BackgroundHandler.MSG_LOAD_ALL); if (mForceLoadAllApps) { mAppSession.onResume(); } else {