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

Commit d2a2fae7 authored by András Kurucz's avatar András Kurucz Committed by Android (Google) Code Review
Browse files

Merge "Remove AmbientState.hasPulsingNotifications()" into main

parents 001d8d49 1f05141c
Loading
Loading
Loading
Loading
+0 −11
Original line number Diff line number Diff line
@@ -262,9 +262,6 @@ public class AmbientState implements Dumpable {
        return mStackHeight;
    }

    /** Tracks the state from HeadsUpManager#hasNotifications() */
    private boolean mHasHeadsUpEntries;

    @Inject
    public AmbientState(
            @NonNull Context context,
@@ -547,10 +544,6 @@ public class AmbientState implements Dumpable {
        mPanelTracking = panelTracking;
    }

    public boolean hasPulsingNotifications() {
        return mPulsing && mHasHeadsUpEntries;
    }

    public void setPulsing(boolean hasPulsing) {
        mPulsing = hasPulsing;
    }
@@ -701,10 +694,6 @@ public class AmbientState implements Dumpable {
        return mAppearFraction;
    }

    public void setHasHeadsUpEntries(boolean hasHeadsUpEntries) {
        mHasHeadsUpEntries = hasHeadsUpEntries;
    }

    public void setStackTopMargin(int stackTopMargin) {
        mStackTopMargin = stackTopMargin;
    }
+0 −7
Original line number Diff line number Diff line
@@ -5379,13 +5379,6 @@ public class NotificationStackScrollLayout extends ViewGroup implements Dumpable
        mTopHeadsUpRow = topHeadsUpRow;
    }

    /**
     * @param numHeadsUp the number of active alerting notifications.
     */
    public void setNumHeadsUp(long numHeadsUp) {
        mAmbientState.setHasHeadsUpEntries(numHeadsUp > 0);
    }

    public boolean getIsExpanded() {
        return mIsExpanded;
    }
+0 −2
Original line number Diff line number Diff line
@@ -689,9 +689,7 @@ public class NotificationStackScrollLayoutController implements Dumpable {

                @Override
                public void onHeadsUpStateChanged(NotificationEntry entry, boolean isHeadsUp) {
                    long numEntries = mHeadsUpManager.getAllEntries().count();
                    NotificationEntry topEntry = mHeadsUpManager.getTopEntry();
                    mView.setNumHeadsUp(numEntries);
                    mView.setTopHeadsUpRow(topEntry != null ? topEntry.getRow() : null);
                    generateHeadsUpAnimation(entry, isHeadsUp);
                }