diff options
author | Selim Cinek <cinek@google.com> | 2014-06-04 15:23:59 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-06-04 15:23:59 +0000 |
commit | 5b8ca9f6111394c75e35cb0371f3e14ebcf0c297 (patch) | |
tree | 56887fb067440d12e4f7c910829b3834010be9ed /packages/SystemUI/src | |
parent | 3b60d3fe9d2490dd5b7d7d9f65377f37134993ae (diff) | |
parent | 5158d82340b6e222da1b9254c5b9667c600e002e (diff) | |
download | frameworks_base-5b8ca9f6111394c75e35cb0371f3e14ebcf0c297.zip frameworks_base-5b8ca9f6111394c75e35cb0371f3e14ebcf0c297.tar.gz frameworks_base-5b8ca9f6111394c75e35cb0371f3e14ebcf0c297.tar.bz2 |
Merge "Disabled touch interaction when in Quick settings." into lmp-preview-dev
Diffstat (limited to 'packages/SystemUI/src')
2 files changed, 14 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java index e30117f..b8a46c4 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java @@ -564,6 +564,7 @@ public class NotificationPanelView extends PanelView implements ? View.INVISIBLE : View.VISIBLE); mScrollView.setTouchEnabled(mQsExpanded); + mNotificationStackScroller.setTouchEnabled(!mQsExpanded); } private void setQsExpansion(float height) { diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java index 4e9a3a4..c29f105 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java @@ -162,7 +162,7 @@ public class NotificationStackScrollLayout extends ViewGroup * animating. */ private boolean mOnlyScrollingInThisMotion; - + private boolean mTouchEnabled = true; private ViewTreeObserver.OnPreDrawListener mChildrenUpdater = new ViewTreeObserver.OnPreDrawListener() { @Override @@ -1811,6 +1811,18 @@ public class NotificationStackScrollLayout extends ViewGroup return mTopPadding + getTranslationY(); } + public void setTouchEnabled(boolean touchEnabled) { + mTouchEnabled = touchEnabled; + } + + @Override + public boolean dispatchTouchEvent(MotionEvent ev) { + if (!mTouchEnabled) { + return false; + } + return super.dispatchTouchEvent(ev); + } + /** * A listener that is notified when some child locations might have changed. */ |