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

Unified Diff: content/browser/renderer_host/render_widget_host_view_android.h

Issue 457913002: Android WebView: flush input events during onVSync (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: subscriberTypes + postInvalidate during VSync Created 6 years, 4 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/renderer_host/render_widget_host_view_android.h
diff --git a/content/browser/renderer_host/render_widget_host_view_android.h b/content/browser/renderer_host/render_widget_host_view_android.h
index 91f9d483731a958e316bb66a69f8ccea1c5f0e67..a242a6915a7d2b8d3e088ee5f9f4b52d7bc7bf76 100644
--- a/content/browser/renderer_host/render_widget_host_view_android.h
+++ b/content/browser/renderer_host/render_widget_host_view_android.h
@@ -247,6 +247,12 @@ class CONTENT_EXPORT RenderWidgetHostViewAndroid
const TextSurroundingSelectionCallback& callback);
private:
+ enum VSyncSubscriberType {
+ INPUT = 1,
+ BEGIN_FRAME = 2
boliu 2014/08/20 02:54:17 ehh, 1 << 0, 1 << 1, 1 << 2....
hush (inactive) 2014/08/20 03:47:21 Done.
+ // Next Type will be 4 because VSyncSubscriberType is used in a bit field.
+ };
+
// TouchSelectionControllerClient implementation.
virtual bool SupportsAnimation() const OVERRIDE;
virtual void SetNeedsAnimate() OVERRIDE;
@@ -317,6 +323,9 @@ class CONTENT_EXPORT RenderWidgetHostViewAndroid
float GetDpiScale() const;
+ // type is a bit field containing one or more VSyncSubscriberType.
+ void SubscribeToVSync(int type);
+
// The model object.
RenderWidgetHostImpl* host_;
@@ -379,6 +388,8 @@ class CONTENT_EXPORT RenderWidgetHostViewAndroid
const bool using_synchronous_compositor_;
+ int vsync_subscribers_;
boliu 2014/08/20 02:54:16 use uint32 or something, to specificy the number o
hush (inactive) 2014/08/20 03:47:21 Done.
+
scoped_ptr<DelegatedFrameEvictor> frame_evictor_;
size_t locks_on_frame_count_;

Powered by Google App Engine
This is Rietveld 408576698