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

Commit 6a5a6f95 authored by Mark Fasheh's avatar Mark Fasheh Committed by Android (Google) Code Review
Browse files

Merge "Update launcher cold startup trace" into main

parents 1398d226 4baa30d1
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -435,6 +435,10 @@ public class Launcher extends StatefulActivity<LauncherState>
        mIsColdStartupAfterReboot = sIsNewProcess
            && !LockedUserState.get(this).isUserUnlockedAtLauncherStartup();
        if (mIsColdStartupAfterReboot) {
            /*
             * This trace is used to calculate the time from create to the point that icons are
             * visible.
             */
            Trace.beginAsyncSection(
                    COLD_STARTUP_TRACE_METHOD_NAME, COLD_STARTUP_TRACE_COOKIE);
        }
@@ -2384,10 +2388,6 @@ public class Launcher extends StatefulActivity<LauncherState>
                    .logEnd(LAUNCHER_LATENCY_STARTUP_TOTAL_DURATION)
                    .log()
                    .reset();
            if (mIsColdStartupAfterReboot) {
                Trace.endAsyncSection(COLD_STARTUP_TRACE_METHOD_NAME,
                        COLD_STARTUP_TRACE_COOKIE);
            }
        });
    }

@@ -2396,6 +2396,10 @@ public class Launcher extends StatefulActivity<LauncherState>
            RunnableList onCompleteSignal, int workspaceItemCount, boolean isBindSync) {
        mModelCallbacks.onInitialBindComplete(boundPages, pendingTasks, onCompleteSignal,
                workspaceItemCount, isBindSync);
        if (mIsColdStartupAfterReboot) {
            Trace.endAsyncSection(COLD_STARTUP_TRACE_METHOD_NAME,
                    COLD_STARTUP_TRACE_COOKIE);
        }
    }

    /**