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

Commit a5e8da1f authored by Matt Pietal's avatar Matt Pietal Committed by Android (Google) Code Review
Browse files

Merge "Fix NSSL migration and falsing" into main

parents f4b92dba a24d8a3f
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ import com.android.systemui.dagger.SysUISingleton
import com.android.systemui.dump.DumpManager
import com.android.systemui.keyguard.WakefulnessLifecycle
import com.android.systemui.keyguard.domain.interactor.NaturalScrollingSettingObserver
import com.android.systemui.keyguard.shared.KeyguardShadeMigrationNssl
import com.android.systemui.media.controls.ui.MediaHierarchyManager
import com.android.systemui.navigationbar.gestural.Utilities.isTrackpadScroll
import com.android.systemui.plugins.ActivityStarter
@@ -888,6 +889,9 @@ class DragDownHelper(
                    isDraggingDown = false
                    isTrackpadReverseScroll = false
                    shadeRepository.setLegacyLockscreenShadeTracking(false)
                    if (KeyguardShadeMigrationNssl.isEnabled) {
                        return true
                    }
                } else {
                    stopDragging()
                    return false
+28 −11
Original line number Diff line number Diff line
@@ -69,6 +69,7 @@ import com.android.systemui.dump.DumpManager;
import com.android.systemui.flags.FeatureFlagsClassic;
import com.android.systemui.flags.Flags;
import com.android.systemui.keyguard.data.repository.KeyguardTransitionRepository;
import com.android.systemui.keyguard.shared.KeyguardShadeMigrationNssl;
import com.android.systemui.keyguard.shared.model.KeyguardState;
import com.android.systemui.keyguard.shared.model.TransitionStep;
import com.android.systemui.media.controls.ui.KeyguardMediaController;
@@ -1957,12 +1958,27 @@ public class NotificationStackScrollLayoutController implements Dumpable {
                    mView.dispatchDownEventToScroller(ev);
                }
            }
            boolean horizontalSwipeWantsIt = false;
            boolean scrollerWantsIt = false;
            if (KeyguardShadeMigrationNssl.isEnabled()) {
                // Reverse the order relative to the else statement. onScrollTouch will reset on an
                // UP event, causing horizontalSwipeWantsIt to be set to true on vertical swipes.
                if (mLongPressedView == null && !mView.isBeingDragged()
                        && !expandingNotification
                        && !mView.getExpandedInThisMotion()
                        && !onlyScrollingInThisMotion
                        && !mView.getDisallowDismissInThisMotion()) {
                    horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev);
                }
                if (mLongPressedView == null && mView.isExpanded() && !mSwipeHelper.isSwiping()
                        && !expandingNotification && !mView.getDisallowScrollingInThisMotion()) {
                    scrollerWantsIt = mView.onScrollTouch(ev);
                }
            } else {
                if (mLongPressedView == null && mView.isExpanded() && !mSwipeHelper.isSwiping()
                        && !expandingNotification && !mView.getDisallowScrollingInThisMotion()) {
                    scrollerWantsIt = mView.onScrollTouch(ev);
                }
            boolean horizontalSwipeWantsIt = false;
                if (mLongPressedView == null && !mView.isBeingDragged()
                        && !expandingNotification
                        && !mView.getExpandedInThisMotion()
@@ -1970,6 +1986,7 @@ public class NotificationStackScrollLayoutController implements Dumpable {
                        && !mView.getDisallowDismissInThisMotion()) {
                    horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev);
                }
            }

            // Check if we need to clear any snooze leavebehinds
            if (guts != null && !NotificationSwipeHelper.isTouchInView(ev, guts)