Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a246eb4a authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add logging to help debug b/200572078." into sc-v2-dev

parents 70cc9ffe 00213384
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -2132,6 +2132,10 @@ public class Launcher extends StatefulActivity<LauncherState> implements Launche

        IntSet result = new IntSet();
        if (visibleIds.isEmpty()) {
            if (TestProtocol.sDebugTracing) {
                Log.d(TestProtocol.NULL_INT_SET, "getPagesToBindSynchronously (1): "
                        + result);
            }
            return result;
        }
        for (int id : orderedScreenIds.toArray()) {
@@ -2152,6 +2156,10 @@ public class Launcher extends StatefulActivity<LauncherState> implements Launche
            // pages being hidden in single panel.
            result.add(pairId);
        }
        if (TestProtocol.sDebugTracing) {
            Log.d(TestProtocol.NULL_INT_SET, "getPagesToBindSynchronously (2): "
                    + result);
        }
        return result;
    }

+11 −0
Original line number Diff line number Diff line
@@ -32,6 +32,7 @@ import com.android.launcher3.model.BgDataModel.FixedContainerItems;
import com.android.launcher3.model.data.AppInfo;
import com.android.launcher3.model.data.ItemInfo;
import com.android.launcher3.model.data.LauncherAppWidgetInfo;
import com.android.launcher3.testing.TestProtocol;
import com.android.launcher3.util.IntArray;
import com.android.launcher3.util.IntSet;
import com.android.launcher3.util.LooperExecutor;
@@ -173,8 +174,18 @@ public abstract class BaseLoaderResults {
            ArrayList<LauncherAppWidgetInfo> currentAppWidgets = new ArrayList<>();
            ArrayList<LauncherAppWidgetInfo> otherAppWidgets = new ArrayList<>();

            if (TestProtocol.sDebugTracing) {
                Log.d(TestProtocol.NULL_INT_SET, "bind (1) currentScreenIds: "
                        + currentScreenIds
                        + ", mCallBacks: "
                        + mCallbacks.getClass().getSimpleName());
            }
            filterCurrentWorkspaceItems(currentScreenIds, mWorkspaceItems, currentWorkspaceItems,
                    otherWorkspaceItems);
            if (TestProtocol.sDebugTracing) {
                Log.d(TestProtocol.NULL_INT_SET, "bind (2) currentScreenIds: "
                        + currentScreenIds);
            }
            filterCurrentWorkspaceItems(currentScreenIds, mAppWidgets, currentAppWidgets,
                    otherAppWidgets);
            final InvariantDeviceProfile idp = mApp.getInvariantDeviceProfile();
+5 −0
Original line number Diff line number Diff line
@@ -31,6 +31,7 @@ import com.android.launcher3.icons.BitmapInfo;
import com.android.launcher3.icons.LauncherIcons;
import com.android.launcher3.model.data.ItemInfo;
import com.android.launcher3.model.data.WorkspaceItemInfo;
import com.android.launcher3.testing.TestProtocol;
import com.android.launcher3.util.IntArray;
import com.android.launcher3.util.IntSet;

@@ -66,6 +67,10 @@ public class ModelUtils {
                (lhs, rhs) -> Integer.compare(lhs.container, rhs.container));
        for (T info : allWorkspaceItems) {
            if (info.container == LauncherSettings.Favorites.CONTAINER_DESKTOP) {
                if (TestProtocol.sDebugTracing) {
                    Log.d(TestProtocol.NULL_INT_SET, "filterCurrentWorkspaceItems: "
                            + currentScreenIds);
                }
                if (currentScreenIds.contains(info.screenId)) {
                    currentScreenItems.add(info);
                    itemsOnScreen.add(info.id);
+1 −0
Original line number Diff line number Diff line
@@ -120,4 +120,5 @@ public final class TestProtocol {
    public static final String WORK_PROFILE_REMOVED = "b/159671700";
    public static final String TASK_VIEW_ID_CRASH = "b/195430732";
    public static final String NO_DROP_TARGET = "b/195031154";
    public static final String NULL_INT_SET = "b/200572078";
}