Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java +1 −0 Original line number Original line Diff line number Diff line Loading @@ -252,6 +252,7 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene findScrollContainer(); findScrollContainer(); if (mScrollContainer != null) { if (mScrollContainer != null) { mScrollContainer.requestDisallowLongPress(); mScrollContainer.requestDisallowLongPress(); mScrollContainer.requestDisallowDismiss(); } } } } return super.onInterceptTouchEvent(ev); return super.onInterceptTouchEvent(ev); Loading packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java +11 −2 Original line number Original line Diff line number Diff line Loading @@ -232,6 +232,7 @@ public class NotificationStackScrollLayout extends ViewGroup * animating. * animating. */ */ private boolean mOnlyScrollingInThisMotion; private boolean mOnlyScrollingInThisMotion; private boolean mDisallowDismissInThisMotion; private boolean mInterceptDelegateEnabled; private boolean mInterceptDelegateEnabled; private boolean mDelegateToScrollView; private boolean mDelegateToScrollView; private boolean mDisallowScrollingInThisMotion; private boolean mDisallowScrollingInThisMotion; Loading Loading @@ -1031,7 +1032,8 @@ public class NotificationStackScrollLayout extends ViewGroup if (!mIsBeingDragged if (!mIsBeingDragged && !mExpandingNotification && !mExpandingNotification && !mExpandedInThisMotion && !mExpandedInThisMotion && !mOnlyScrollingInThisMotion) { && !mOnlyScrollingInThisMotion && !mDisallowDismissInThisMotion) { horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev); horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev); } } return horizontalSwipeWantsIt || scrollerWantsIt || expandWantsIt || super.onTouchEvent(ev); return horizontalSwipeWantsIt || scrollerWantsIt || expandWantsIt || super.onTouchEvent(ev); Loading Loading @@ -2013,7 +2015,8 @@ public class NotificationStackScrollLayout extends ViewGroup if (!mIsBeingDragged if (!mIsBeingDragged && !mExpandingNotification && !mExpandingNotification && !mExpandedInThisMotion && !mExpandedInThisMotion && !mOnlyScrollingInThisMotion) { && !mOnlyScrollingInThisMotion && !mDisallowDismissInThisMotion) { swipeWantsIt = mSwipeHelper.onInterceptTouchEvent(ev); swipeWantsIt = mSwipeHelper.onInterceptTouchEvent(ev); } } return swipeWantsIt || scrollWantsIt || expandWantsIt || super.onInterceptTouchEvent(ev); return swipeWantsIt || scrollWantsIt || expandWantsIt || super.onInterceptTouchEvent(ev); Loading Loading @@ -2041,6 +2044,7 @@ public class NotificationStackScrollLayout extends ViewGroup mExpandedInThisMotion = false; mExpandedInThisMotion = false; mOnlyScrollingInThisMotion = !mScroller.isFinished(); mOnlyScrollingInThisMotion = !mScroller.isFinished(); mDisallowScrollingInThisMotion = false; mDisallowScrollingInThisMotion = false; mDisallowDismissInThisMotion = false; mTouchIsClick = true; mTouchIsClick = true; mInitialTouchX = ev.getX(); mInitialTouchX = ev.getX(); mInitialTouchY = ev.getY(); mInitialTouchY = ev.getY(); Loading Loading @@ -2705,6 +2709,11 @@ public class NotificationStackScrollLayout extends ViewGroup removeLongPressCallback(); removeLongPressCallback(); } } @Override public void requestDisallowDismiss() { mDisallowDismissInThisMotion = true; } public void removeLongPressCallback() { public void removeLongPressCallback() { mSwipeHelper.removeLongPressCallback(); mSwipeHelper.removeLongPressCallback(); } } Loading packages/SystemUI/src/com/android/systemui/statusbar/stack/ScrollContainer.java +5 −0 Original line number Original line Diff line number Diff line Loading @@ -33,4 +33,9 @@ public interface ScrollContainer { * Request that the view is made visible by scrolling to it. * Request that the view is made visible by scrolling to it. */ */ void scrollTo(View v); void scrollTo(View v); /** * Request that the view does not dismiss for the current touch. */ void requestDisallowDismiss(); } } Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java +1 −0 Original line number Original line Diff line number Diff line Loading @@ -252,6 +252,7 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene findScrollContainer(); findScrollContainer(); if (mScrollContainer != null) { if (mScrollContainer != null) { mScrollContainer.requestDisallowLongPress(); mScrollContainer.requestDisallowLongPress(); mScrollContainer.requestDisallowDismiss(); } } } } return super.onInterceptTouchEvent(ev); return super.onInterceptTouchEvent(ev); Loading
packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java +11 −2 Original line number Original line Diff line number Diff line Loading @@ -232,6 +232,7 @@ public class NotificationStackScrollLayout extends ViewGroup * animating. * animating. */ */ private boolean mOnlyScrollingInThisMotion; private boolean mOnlyScrollingInThisMotion; private boolean mDisallowDismissInThisMotion; private boolean mInterceptDelegateEnabled; private boolean mInterceptDelegateEnabled; private boolean mDelegateToScrollView; private boolean mDelegateToScrollView; private boolean mDisallowScrollingInThisMotion; private boolean mDisallowScrollingInThisMotion; Loading Loading @@ -1031,7 +1032,8 @@ public class NotificationStackScrollLayout extends ViewGroup if (!mIsBeingDragged if (!mIsBeingDragged && !mExpandingNotification && !mExpandingNotification && !mExpandedInThisMotion && !mExpandedInThisMotion && !mOnlyScrollingInThisMotion) { && !mOnlyScrollingInThisMotion && !mDisallowDismissInThisMotion) { horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev); horizontalSwipeWantsIt = mSwipeHelper.onTouchEvent(ev); } } return horizontalSwipeWantsIt || scrollerWantsIt || expandWantsIt || super.onTouchEvent(ev); return horizontalSwipeWantsIt || scrollerWantsIt || expandWantsIt || super.onTouchEvent(ev); Loading Loading @@ -2013,7 +2015,8 @@ public class NotificationStackScrollLayout extends ViewGroup if (!mIsBeingDragged if (!mIsBeingDragged && !mExpandingNotification && !mExpandingNotification && !mExpandedInThisMotion && !mExpandedInThisMotion && !mOnlyScrollingInThisMotion) { && !mOnlyScrollingInThisMotion && !mDisallowDismissInThisMotion) { swipeWantsIt = mSwipeHelper.onInterceptTouchEvent(ev); swipeWantsIt = mSwipeHelper.onInterceptTouchEvent(ev); } } return swipeWantsIt || scrollWantsIt || expandWantsIt || super.onInterceptTouchEvent(ev); return swipeWantsIt || scrollWantsIt || expandWantsIt || super.onInterceptTouchEvent(ev); Loading Loading @@ -2041,6 +2044,7 @@ public class NotificationStackScrollLayout extends ViewGroup mExpandedInThisMotion = false; mExpandedInThisMotion = false; mOnlyScrollingInThisMotion = !mScroller.isFinished(); mOnlyScrollingInThisMotion = !mScroller.isFinished(); mDisallowScrollingInThisMotion = false; mDisallowScrollingInThisMotion = false; mDisallowDismissInThisMotion = false; mTouchIsClick = true; mTouchIsClick = true; mInitialTouchX = ev.getX(); mInitialTouchX = ev.getX(); mInitialTouchY = ev.getY(); mInitialTouchY = ev.getY(); Loading Loading @@ -2705,6 +2709,11 @@ public class NotificationStackScrollLayout extends ViewGroup removeLongPressCallback(); removeLongPressCallback(); } } @Override public void requestDisallowDismiss() { mDisallowDismissInThisMotion = true; } public void removeLongPressCallback() { public void removeLongPressCallback() { mSwipeHelper.removeLongPressCallback(); mSwipeHelper.removeLongPressCallback(); } } Loading
packages/SystemUI/src/com/android/systemui/statusbar/stack/ScrollContainer.java +5 −0 Original line number Original line Diff line number Diff line Loading @@ -33,4 +33,9 @@ public interface ScrollContainer { * Request that the view is made visible by scrolling to it. * Request that the view is made visible by scrolling to it. */ */ void scrollTo(View v); void scrollTo(View v); /** * Request that the view does not dismiss for the current touch. */ void requestDisallowDismiss(); } }