Add logs for the app binding flow.

This can help debug issues like the blank all apps issue.

Bug: 393406722
Test: Manual
Flag: EXEMPT bugfix
Change-Id: I0481531313d3633c46e63646511b59e081046cf8
This commit is contained in:
Andy Wickham committed 2025-03-20 15:29:59 +00:00
1 parent e58dac962c
commit a97f179909
4 files changed
+24 -2

No files matched your search

@@ -575,6 +575,7 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
}
protected void rebindAdapters(boolean force) {
Log.d(TAG, "rebindAdapters: force: " + force);
if (mSearchTransitionController.isRunning()) {
mRebindAdaptersAfterSearchAnimation = true;
return;
@@ -583,6 +584,7 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
boolean showTabs = shouldShowTabs();
if (showTabs == mUsingTabs && !force) {
Log.d(TAG, "rebindAdapters: Not needed.");
return;
}
@@ -678,6 +680,7 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
}
private void replaceAppsRVContainer(boolean showTabs) {
Log.d(TAG, "replaceAppsRVContainer: showTabs: " + showTabs);
for (int i = AdapterHolder.MAIN; i <= AdapterHolder.WORK; i++) {
AdapterHolder adapterHolder = mAH.get(i);
if (adapterHolder.mRecyclerView != null) {
@@ -711,7 +714,6 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
mWorkManager.reset();
post(() -> mAH.get(AdapterHolder.WORK).applyPadding());
} else {
mWorkManager.detachWorkUtilityViews();
mViewPager = null;
@@ -1017,6 +1019,7 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
@VisibleForTesting
public void onAppsUpdated() {
Log.d(TAG, "onAppsUpdated; number of apps: " + mAllAppsStore.getApps().length);
mHasWorkApps = Stream.of(mAllAppsStore.getApps())
.anyMatch(mWorkManager.getItemInfoMatcher());
mHasPrivateApps = Stream.of(mAllAppsStore.getApps())