summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTony Wickham <twickham@google.com>2016-07-26 16:20:25 -0700
committerTony Wickham <twickham@google.com>2016-07-26 16:54:31 -0700
commit47c5a495792f37c9fe443aa896d539d264432509 (patch)
tree71f5f250370b0bf77ec5741df7962fa5369bfda8 /src
parente9381d60cc18bac394c1e59196cf764bb3a49527 (diff)
downloadandroid_packages_apps_Trebuchet-47c5a495792f37c9fe443aa896d539d264432509.tar.gz
android_packages_apps_Trebuchet-47c5a495792f37c9fe443aa896d539d264432509.tar.bz2
android_packages_apps_Trebuchet-47c5a495792f37c9fe443aa896d539d264432509.zip
Remove DisallowIntercept runnable from ShortcutsContainerListener.
This was copied from ForwardingListener, which was used to prevent scrollable parents from intercepting swipe gestures. We only use long press, so we don't want to do this. Bug: 30230790 Change-Id: Icbb692c1b46ad8287af2942baa452f3578fee679
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher3/shortcuts/ShortcutsContainerListener.java29
1 files changed, 0 insertions, 29 deletions
diff --git a/src/com/android/launcher3/shortcuts/ShortcutsContainerListener.java b/src/com/android/launcher3/shortcuts/ShortcutsContainerListener.java
index f94595b54..507939a8e 100644
--- a/src/com/android/launcher3/shortcuts/ShortcutsContainerListener.java
+++ b/src/com/android/launcher3/shortcuts/ShortcutsContainerListener.java
@@ -4,7 +4,6 @@ import android.os.SystemClock;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewConfiguration;
-import android.view.ViewParent;
import com.android.launcher3.BubbleTextView;
import com.android.launcher3.CheckLongPressHelper;
@@ -22,18 +21,12 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
/** Scaled touch slop, used for detecting movement outside bounds. */
private final float mScaledTouchSlop;
- /** Timeout before disallowing intercept on the source's parent. */
- private final int mTapTimeout;
-
/** Timeout before accepting a long-press to start forwarding. */
private final int mLongPressTimeout;
/** Source view from which events are forwarded. */
private final BubbleTextView mSrcIcon;
- /** Runnable used to prevent conflicts with scrolling parents. */
- private Runnable mDisallowIntercept;
-
/** Runnable used to trigger forwarding on long-press. */
private Runnable mTriggerLongPress;
@@ -56,7 +49,6 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
public ShortcutsContainerListener(BubbleTextView icon) {
mSrcIcon = icon;
mScaledTouchSlop = ViewConfiguration.get(icon.getContext()).getScaledTouchSlop();
- mTapTimeout = ViewConfiguration.getTapTimeout();
mLongPressTimeout = CheckLongPressHelper.DEFAULT_LONG_PRESS_TIMEOUT;
@@ -113,10 +105,6 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
public void onViewDetachedFromWindow(View v) {
mForwarding = false;
mActivePointerId = MotionEvent.INVALID_POINTER_ID;
-
- if (mDisallowIntercept != null) {
- mSrcIcon.removeCallbacks(mDisallowIntercept);
- }
}
/**
@@ -158,11 +146,6 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
case MotionEvent.ACTION_DOWN:
mActivePointerId = srcEvent.getPointerId(0);
- if (mDisallowIntercept == null) {
- mDisallowIntercept = new DisallowIntercept();
- }
- src.postDelayed(mDisallowIntercept, mTapTimeout);
-
if (mTriggerLongPress == null) {
mTriggerLongPress = new TriggerLongPress();
}
@@ -195,10 +178,6 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
if (mTriggerLongPress != null) {
mSrcIcon.removeCallbacks(mTriggerLongPress);
}
-
- if (mDisallowIntercept != null) {
- mSrcIcon.removeCallbacks(mDisallowIntercept);
- }
}
private void onLongPress() {
@@ -265,14 +244,6 @@ public class ShortcutsContainerListener implements View.OnTouchListener,
return handled && keepForwarding;
}
- private class DisallowIntercept implements Runnable {
- @Override
- public void run() {
- final ViewParent parent = mSrcIcon.getParent();
- parent.requestDisallowInterceptTouchEvent(true);
- }
- }
-
private class TriggerLongPress implements Runnable {
@Override
public void run() {