diff options
| author | 2013-01-22 18:10:52 +0900 | |
|---|---|---|
| committer | 2013-01-22 18:10:52 +0900 | |
| commit | f449c0c381239dc0f78b0f01ecfb3889e056a597 (patch) | |
| tree | 465502c36f564cdcf405efc72b184dae256e23bf | |
| parent | b1e16f11ffd3a391be1a44a352c122b6dad1e8a5 (diff) | |
fix hover events consume issue
View#onHoverEvent() would always consume hover events over the view
if an application window has the clickable view/widget on it.
That's happened even if accessibility/talkback is disabled.
So those events will not dispatch to activity#onGenericMotionEvent().
The onHoverEvent method should return a real consumed state.
Change-Id: I9cac13b82866e5cdda0b03befb0de752a0a2e741
| -rw-r--r-- | core/java/android/view/View.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java index ff44475a7e28..b3f9b3181e98 100644 --- a/core/java/android/view/View.java +++ b/core/java/android/view/View.java @@ -8064,8 +8064,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback, // in onHoverEvent. // Note that onGenericMotionEvent will be called by default when // onHoverEvent returns false (refer to dispatchGenericMotionEvent). - dispatchGenericMotionEventInternal(event); - return true; + return dispatchGenericMotionEventInternal(event); } return false; |