summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/notification
diff options
context:
space:
mode:
authorTony Wickham <twickham@google.com>2017-02-15 16:03:27 -0800
committerTony Wickham <twickham@google.com>2017-02-15 16:05:40 -0800
commit7aefaae5d9e0938e5268238d397d40d8959dc7ba (patch)
tree27f219148737d1390fedcb991dcb6f4443892d8f /src/com/android/launcher3/notification
parenta59402f98c0d3f85a45344657baa9b208e9eea32 (diff)
downloadandroid_packages_apps_Trebuchet-7aefaae5d9e0938e5268238d397d40d8959dc7ba.tar.gz
android_packages_apps_Trebuchet-7aefaae5d9e0938e5268238d397d40d8959dc7ba.tar.bz2
android_packages_apps_Trebuchet-7aefaae5d9e0938e5268238d397d40d8959dc7ba.zip
Ignore touches before notification is populated
Bug: 35398757 Change-Id: I24f1b66787af7c7caeb325e9a1f3e6ef86e62b81
Diffstat (limited to 'src/com/android/launcher3/notification')
-rw-r--r--src/com/android/launcher3/notification/NotificationItemView.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/com/android/launcher3/notification/NotificationItemView.java b/src/com/android/launcher3/notification/NotificationItemView.java
index 639447dc3..c9b3940b8 100644
--- a/src/com/android/launcher3/notification/NotificationItemView.java
+++ b/src/com/android/launcher3/notification/NotificationItemView.java
@@ -83,12 +83,20 @@ public class NotificationItemView extends PopupItemView implements LogContainerP
@Override
public boolean onInterceptTouchEvent(MotionEvent ev) {
+ if (mMainView.getNotificationInfo() == null) {
+ // The notification hasn't been populated yet.
+ return false;
+ }
getParent().requestDisallowInterceptTouchEvent(true);
return mSwipeHelper.onInterceptTouchEvent(ev);
}
@Override
public boolean onTouchEvent(MotionEvent ev) {
+ if (mMainView.getNotificationInfo() == null) {
+ // The notification hasn't been populated yet.
+ return false;
+ }
return mSwipeHelper.onTouchEvent(ev) || super.onTouchEvent(ev);
}