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

Commit e59dc404 authored by Jason Monk's avatar Jason Monk
Browse files

Remove stack scroller references from StatusBar

Try to move as much logic up over into stack scroller as possible.

Things that can't move, funnel through NotificationPanel to make the
interface between StatusBar and NotificationPanel more explicit.

Test: Existing tests

Change-Id: I5fa36a9d5d0a8c7f76b9d1843c0733a5758b5838
parent 83f8d6d2
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -23,6 +23,7 @@ import android.os.Looper;
import android.os.Process;
import android.os.ServiceManager;
import android.util.ArrayMap;
import android.util.DisplayMetrics;
import android.view.IWindowManager;
import android.view.WindowManagerGlobal;

@@ -51,6 +52,7 @@ import com.android.systemui.statusbar.VibratorHelper;
import com.android.systemui.statusbar.phone.ConfigurationControllerImpl;
import com.android.systemui.statusbar.phone.DarkIconDispatcherImpl;
import com.android.systemui.statusbar.phone.LightBarController;
import com.android.systemui.statusbar.phone.LockscreenGestureLogger;
import com.android.systemui.statusbar.phone.ManagedProfileController;
import com.android.systemui.statusbar.phone.ManagedProfileControllerImpl;
import com.android.systemui.statusbar.phone.StatusBarIconController;
@@ -328,6 +330,12 @@ public class Dependency extends SystemUI {
        mProviders.put(IStatusBarService.class, () -> IStatusBarService.Stub.asInterface(
                ServiceManager.getService(Context.STATUS_BAR_SERVICE)));

        // Single instance of DisplayMetrics, gets updated by StatusBar, but can be used
        // anywhere it is needed.
        mProviders.put(DisplayMetrics.class, () -> new DisplayMetrics());

        mProviders.put(LockscreenGestureLogger.class, () -> new LockscreenGestureLogger());

        // Put all dependencies above here so the factory can override them if it wants.
        SystemUIFactory.getInstance().injectDependencies(mProviders, mContext);

+2 −2
Original line number Diff line number Diff line
@@ -43,12 +43,12 @@ public class StatusBarStateController {
            return;
        }
        synchronized (mListeners) {
            for (StateListener listener : mListeners) {
            for (StateListener listener : new ArraySet<>(mListeners)) {
                listener.onStatePreChange(mState, state);
            }
            mLastState = mState;
            mState = state;
            for (StateListener listener : mListeners) {
            for (StateListener listener : new ArraySet<>(mListeners)) {
                listener.onStateChanged(mState);
            }
        }
+1 −1
Original line number Diff line number Diff line
@@ -91,7 +91,7 @@ public class CarStatusBar extends StatusBar implements
        mActivityManagerWrapper = ActivityManagerWrapper.getInstance();
        mActivityManagerWrapper.registerTaskStackListener(mTaskStackListener);

        mStackScroller.setScrollingEnabled(true);
        mNotificationPanel.setScrollingEnabled(true);

        createBatteryController();
        mCarBatteryController.startListening();
+1 −0
Original line number Diff line number Diff line
@@ -417,6 +417,7 @@ public abstract class ExpandableView extends FrameLayout {

    public void setWillBeGone(boolean willBeGone) {
        mWillBeGone = willBeGone;
        invalidate();
    }

    public int getMinClipTopAmount() {
+460 −91

File changed.

Preview size limit exceeded, changes collapsed.

Loading