OSDN Git Service

am 91ff85da: am 67af29f6: Merge "Fix touch intercept bug in ResolverDrawerLayout...
authorAdam Powell <adamp@google.com>
Tue, 16 Dec 2014 18:13:01 +0000 (18:13 +0000)
committerAndroid Git Automerger <android-git-automerger@android.com>
Tue, 16 Dec 2014 18:13:01 +0000 (18:13 +0000)
* commit '91ff85da1a2a106c8ddb5e204928e0d6ef094283':
  Fix touch intercept bug in ResolverDrawerLayout

core/java/com/android/internal/widget/ResolverDrawerLayout.java

index 25b4945..ed7af2f 100644 (file)
@@ -217,8 +217,9 @@ public class ResolverDrawerLayout extends ViewGroup {
                 mInitialTouchX = x;
                 mInitialTouchY = mLastTouchY = y;
                 mActivePointerId = ev.getPointerId(0);
-                mIsDragging = findChildUnder(mInitialTouchX, mInitialTouchY) != null;
-                handled = (!mIsDragging && mOnDismissedListener != null) || mCollapsibleHeight > 0;
+                final boolean hitView = findChildUnder(mInitialTouchX, mInitialTouchY) != null;
+                handled = (!hitView && mOnDismissedListener != null) || mCollapsibleHeight > 0;
+                mIsDragging = hitView && handled;
                 abortAnimation();
             }
             break;