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

Commit 8758311c authored by Winson Chung's avatar Winson Chung
Browse files

Defer listening for notification changes until resume

Bug: 134964922
Test: Take a systrace while swiping up, ensure there are no resource icon
      loads other than the icon for the current app while launcher is
      starting

Change-Id: I469a2089df02434918125b005cd795f5514ec389
parent c25d9753
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -888,7 +888,6 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
            mLauncherCallbacks.onStart();
        }
        mAppWidgetHost.setListenIfResumed(true);
        NotificationListener.setNotificationsChangedListener(mPopupDataProvider);
        RaceConditionTracker.onEvent(ON_START_EVT, EXIT);
    }

@@ -908,6 +907,9 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
            // Refresh shortcuts if the permission changed.
            mModel.refreshShortcutsIfRequired();

            // Set the notification listener and fetch updated notifications when we resume
            NotificationListener.setNotificationsChangedListener(mPopupDataProvider);

            DiscoveryBounce.showForHomeIfNeeded(this);

            if (mPendingActivityRequestCode != -1 && isInState(NORMAL)) {