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

Unified Diff: content/browser/android/content_view_core_impl.h

Issue 181833003: [Android] Out with the Android GR, in with the new unified C++ GR (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix type count Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/android/content_view_core_impl.h
diff --git a/content/browser/android/content_view_core_impl.h b/content/browser/android/content_view_core_impl.h
index 595f4188d6d12bca33cee1a78d93e0cf1ba1f2e4..93d55c43d694a46a570d18b75e40925f78cbb10f 100644
--- a/content/browser/android/content_view_core_impl.h
+++ b/content/browser/android/content_view_core_impl.h
@@ -14,7 +14,7 @@
#include "base/i18n/rtl.h"
#include "base/memory/scoped_ptr.h"
#include "base/process/process.h"
-#include "content/browser/renderer_host/input/touch_disposition_gesture_filter.h"
+#include "content/browser/renderer_host/input/content_gesture_provider.h"
#include "content/browser/renderer_host/render_widget_host_view_android.h"
#include "content/browser/web_contents/web_contents_impl.h"
#include "content/public/browser/android/content_view_core.h"
@@ -37,8 +37,8 @@ struct MenuItem;
// TODO(jrg): this is a shell. Upstream the rest.
class ContentViewCoreImpl : public ContentViewCore,
+ public ContentGestureProviderClient,
public NotificationObserver,
- public TouchDispositionGestureFilterClient,
public WebContentsObserver {
public:
static ContentViewCoreImpl* FromWebContents(WebContents* web_contents);
@@ -96,10 +96,9 @@ class ContentViewCoreImpl : public ContentViewCore,
JNIEnv* env, jobject obj) const;
jboolean IsIncognito(JNIEnv* env, jobject obj);
void SendOrientationChangeEvent(JNIEnv* env, jobject obj, jint orientation);
- void OnTouchEventHandlingBegin(JNIEnv* env,
- jobject obj,
- jobject motion_event);
- void OnTouchEventHandlingEnd(JNIEnv* env, jobject obj);
+ jboolean OnTouchEvent(JNIEnv* env,
+ jobject obj,
+ jobject motion_event);
jboolean SendMouseMoveEvent(JNIEnv* env,
jobject obj,
jlong time_ms,
@@ -122,22 +121,11 @@ class ContentViewCoreImpl : public ContentViewCore,
void SingleTap(JNIEnv* env, jobject obj, jlong time_ms,
jfloat x, jfloat y,
jboolean disambiguation_popup_tap);
- void SingleTapUnconfirmed(JNIEnv* env, jobject obj, jlong time_ms,
- jfloat x, jfloat y);
- void ShowPress(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,
jfloat x, jfloat y) ;
void LongPress(JNIEnv* env, jobject obj, jlong time_ms,
jfloat x, jfloat y,
jboolean disambiguation_popup_tap);
- void LongTap(JNIEnv* env, jobject obj, jlong time_ms,
- jfloat x, jfloat y,
- jboolean disambiguation_popup_tap);
void PinchBegin(JNIEnv* env, jobject obj, jlong time_ms, jfloat x, jfloat y);
void PinchEnd(JNIEnv* env, jobject obj, jlong time_ms);
void PinchBy(JNIEnv* env, jobject obj, jlong time_ms,
@@ -147,6 +135,17 @@ class ContentViewCoreImpl : public ContentViewCore,
jfloat x2, jfloat y2);
void MoveCaret(JNIEnv* env, jobject obj, jfloat x, jfloat y);
+ void ResetGestureDetectors(JNIEnv* env, jobject obj);
+ void IgnoreRemainingTouchEvents(JNIEnv* env, jobject obj);
+ void OnWindowFocusLost(JNIEnv* env, jobject obj);
+ void SetDoubleTapSupportForPageEnabled(JNIEnv* env,
+ jobject obj,
+ jboolean enabled);
+ void SetDoubleTapSupportEnabled(JNIEnv* env, jobject obj, jboolean enabled);
+ void SetMultiTouchZoomSupportEnabled(JNIEnv* env,
+ jobject obj,
+ jboolean enabled);
+
void LoadIfNecessary(JNIEnv* env, jobject obj);
void RequestRestoreLoad(JNIEnv* env, jobject obj);
void StopLoading(JNIEnv* env, jobject obj);
@@ -216,12 +215,6 @@ class ContentViewCoreImpl : public ContentViewCore,
jboolean IsShowingInterstitialPage(JNIEnv* env, jobject obj);
void SetAccessibilityEnabled(JNIEnv* env, jobject obj, bool enabled);
- void SendActionAfterDoubleTapUma(JNIEnv* env,
- jobject obj,
- jint type,
- jboolean has_delay,
- jint count);
- void SendSingleTapUma(JNIEnv* env, jobject obj, jint type, jint count);
void ExtractSmartClipData(JNIEnv* env,
jobject obj,
@@ -325,9 +318,8 @@ class ContentViewCoreImpl : public ContentViewCore,
virtual void RenderViewReady() OVERRIDE;
virtual void WebContentsDestroyed(WebContents* web_contents) OVERRIDE;
- // TouchDispositionGestureFilterClient implementation.
- virtual void ForwardGestureEvent(
- const blink::WebGestureEvent& event) OVERRIDE;
+ // ContentGestureProviderClient implementation.
+ virtual void OnGestureEvent(const blink::WebGestureEvent& event) OVERRIDE;
// --------------------------------------------------------------------------
// Other private methods and data
@@ -350,7 +342,6 @@ class ContentViewCoreImpl : public ContentViewCore,
void DeleteScaledSnapshotTexture();
void SendGestureEvent(const blink::WebGestureEvent& event);
- void SendSyntheticGestureEvent(const blink::WebGestureEvent& event);
// Update focus state of the RenderWidgetHostView.
void SetFocusInternal(bool focused);
@@ -384,18 +375,16 @@ class ContentViewCoreImpl : public ContentViewCore,
// The owning window that has a hold of main application activity.
ui::WindowAndroid* window_android_;
+ // Provides gesture synthesis given a stream of touch events (derived from
+ // Android MotionEvent's) and touch event acks.
+ ContentGestureProvider gesture_provider_;
+
// The cache of device's current orientation set from Java side, this value
// will be sent to Renderer once it is ready.
int device_orientation_;
bool geolocation_needs_pause_;
- // Handles gesture dispatch as the generating touch events are ack'ed.
- TouchDispositionGestureFilter touch_disposition_gesture_filter_;
- bool handling_touch_event_;
- blink::WebTouchEvent pending_touch_event_;
- GestureEventPacket pending_gesture_packet_;
-
DISALLOW_COPY_AND_ASSIGN(ContentViewCoreImpl);
};
« no previous file with comments | « no previous file | content/browser/android/content_view_core_impl.cc » ('j') | content/browser/android/content_view_core_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698