summaryrefslogtreecommitdiffstats
path: root/content/browser
diff options
context:
space:
mode:
authorjdduke@chromium.org <jdduke@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-05 23:14:03 +0000
committerjdduke@chromium.org <jdduke@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-05 23:14:03 +0000
commitfb28ad1f2e04da8dfc03eb1e97de079c457ecc63 (patch)
tree39f518c509626a29bd4013bcccb08ce1daa954f8 /content/browser
parent19548023a7dbc63ddceacdc26c040de626f5ed9c (diff)
downloadchromium_src-fb28ad1f2e04da8dfc03eb1e97de079c457ecc63.zip
chromium_src-fb28ad1f2e04da8dfc03eb1e97de079c457ecc63.tar.gz
chromium_src-fb28ad1f2e04da8dfc03eb1e97de079c457ecc63.tar.bz2
[Android] Always complete a TapDown gesture with TapCancel if necessary
A TapDown gesture should always be accompanied by a tap-ending event. Previously, ShowPress gestures were tracked by ContentViewGestureHandler to indicate if a TapCancel event was necessary. However, the addition of an immediate TapDown supercedes this requirement. Send synthetic TapCancel if necessary to complete the TapDown. BUG=313830 Review URL: https://codereview.chromium.org/55313004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@233128 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser')
-rw-r--r--content/browser/android/content_view_core_impl.cc10
-rw-r--r--content/browser/android/content_view_core_impl.h4
2 files changed, 7 insertions, 7 deletions
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index c423adb..8f1179a 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -1056,11 +1056,11 @@ void ContentViewCoreImpl::ShowPressState(JNIEnv* env, jobject obj,
SendGestureEvent(event);
}
-void ContentViewCoreImpl::ShowPressCancel(JNIEnv* env,
- jobject obj,
- jlong time_ms,
- jfloat x,
- jfloat y) {
+void ContentViewCoreImpl::TapCancel(JNIEnv* env,
+ jobject obj,
+ jlong time_ms,
+ jfloat x,
+ jfloat y) {
WebGestureEvent event = MakeGestureEvent(
WebInputEvent::GestureTapCancel, time_ms, x, y);
SendGestureEvent(event);
diff --git a/content/browser/android/content_view_core_impl.h b/content/browser/android/content_view_core_impl.h
index f1e43cc..aa4d04c 100644
--- a/content/browser/android/content_view_core_impl.h
+++ b/content/browser/android/content_view_core_impl.h
@@ -121,8 +121,8 @@ class ContentViewCoreImpl : public ContentViewCore,
jfloat x, jfloat y);
void ShowPressState(JNIEnv* env, jobject obj, jlong time_ms,
jfloat x, jfloat y);
- void ShowPressCancel(JNIEnv* env, jobject obj, jlong time_ms,
- jfloat x, jfloat y);
+ void TapCancel(JNIEnv* env, jobject obj, jlong time_ms,
+ jfloat x, jfloat y);
void TapDown(JNIEnv* env, jobject obj, jlong time_ms,
jfloat x, jfloat y);
void DoubleTap(JNIEnv* env, jobject obj, jlong time_ms,