Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(35)

Side by Side Diff: content/browser/android/content_view_core_impl.cc

Issue 40913002: Reenable the tap down gesture. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Freshen Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/renderer_host/input/gesture_event_filter.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/android/content_view_core_impl.h" 5 #include "content/browser/android/content_view_core_impl.h"
6 6
7 #include "base/android/jni_android.h" 7 #include "base/android/jni_android.h"
8 #include "base/android/jni_array.h" 8 #include "base/android/jni_array.h"
9 #include "base/android/jni_string.h" 9 #include "base/android/jni_string.h"
10 #include "base/android/scoped_java_ref.h" 10 #include "base/android/scoped_java_ref.h"
(...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after
1054 jfloat x, 1054 jfloat x,
1055 jfloat y) { 1055 jfloat y) {
1056 WebGestureEvent event = MakeGestureEvent( 1056 WebGestureEvent event = MakeGestureEvent(
1057 WebInputEvent::GestureTapCancel, time_ms, x, y); 1057 WebInputEvent::GestureTapCancel, time_ms, x, y);
1058 SendGestureEvent(event); 1058 SendGestureEvent(event);
1059 } 1059 }
1060 1060
1061 void ContentViewCoreImpl::TapDown(JNIEnv* env, jobject obj, 1061 void ContentViewCoreImpl::TapDown(JNIEnv* env, jobject obj,
1062 jlong time_ms, 1062 jlong time_ms,
1063 jfloat x, jfloat y) { 1063 jfloat x, jfloat y) {
1064 // TODO - once Blink accepts tap down events correctly, fire tap down 1064 WebGestureEvent event = MakeGestureEvent(
1065 // here. See crbug.com/302752. 1065 WebInputEvent::GestureTapDown, time_ms, x, y);
1066 SendGestureEvent(event);
1066 } 1067 }
1067 1068
1068 void ContentViewCoreImpl::DoubleTap(JNIEnv* env, jobject obj, jlong time_ms, 1069 void ContentViewCoreImpl::DoubleTap(JNIEnv* env, jobject obj, jlong time_ms,
1069 jfloat x, jfloat y) { 1070 jfloat x, jfloat y) {
1070 WebGestureEvent event = MakeGestureEvent( 1071 WebGestureEvent event = MakeGestureEvent(
1071 WebInputEvent::GestureDoubleTap, time_ms, x, y); 1072 WebInputEvent::GestureDoubleTap, time_ms, x, y);
1072 SendGestureEvent(event); 1073 SendGestureEvent(event);
1073 } 1074 }
1074 1075
1075 void ContentViewCoreImpl::LongPress(JNIEnv* env, jobject obj, jlong time_ms, 1076 void ContentViewCoreImpl::LongPress(JNIEnv* env, jobject obj, jlong time_ms,
(...skipping 553 matching lines...) Expand 10 before | Expand all | Expand 10 after
1629 reinterpret_cast<ui::ViewAndroid*>(view_android), 1630 reinterpret_cast<ui::ViewAndroid*>(view_android),
1630 reinterpret_cast<ui::WindowAndroid*>(window_android)); 1631 reinterpret_cast<ui::WindowAndroid*>(window_android));
1631 return reinterpret_cast<jint>(view); 1632 return reinterpret_cast<jint>(view);
1632 } 1633 }
1633 1634
1634 bool RegisterContentViewCore(JNIEnv* env) { 1635 bool RegisterContentViewCore(JNIEnv* env) {
1635 return RegisterNativesImpl(env); 1636 return RegisterNativesImpl(env);
1636 } 1637 }
1637 1638
1638 } // namespace content 1639 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/input/gesture_event_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698