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

Unified Diff: content/renderer/pepper/pepper_plugin_instance_impl.h

Issue 252663002: Track plugin input event latency (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix win & mac build Created 6 years, 7 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/renderer/pepper/pepper_plugin_instance_impl.h
diff --git a/content/renderer/pepper/pepper_plugin_instance_impl.h b/content/renderer/pepper/pepper_plugin_instance_impl.h
index 68771efa5ead20f0ce4df6716b5c4b302197b2db..9d067a94a0e51ca5e9623c02398ae02cc0f529f4 100644
--- a/content/renderer/pepper/pepper_plugin_instance_impl.h
+++ b/content/renderer/pepper/pepper_plugin_instance_impl.h
@@ -55,6 +55,7 @@
#include "third_party/WebKit/public/web/WebPlugin.h"
#include "third_party/WebKit/public/web/WebUserGestureToken.h"
#include "ui/base/ime/text_input_type.h"
+#include "ui/events/latency_info.h"
#include "ui/gfx/rect.h"
#include "url/gurl.h"
@@ -404,6 +405,7 @@ class CONTENT_EXPORT PepperPluginInstanceImpl
uint32_t event_classes) OVERRIDE;
virtual void ClearInputEventRequest(PP_Instance instance,
uint32_t event_classes) OVERRIDE;
+ virtual void StartTrackingLatency(PP_Instance instance) OVERRIDE;
virtual void ZoomChanged(PP_Instance instance, double factor) OVERRIDE;
virtual void ZoomLimitsChanged(PP_Instance instance,
double minimum_factor,
@@ -507,6 +509,8 @@ class CONTENT_EXPORT PepperPluginInstanceImpl
// RenderFrameObserver
virtual void OnDestruct() OVERRIDE;
+ void AddLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info);
+
private:
friend class base::RefCounted<PepperPluginInstanceImpl>;
friend class PpapiUnittest;
@@ -864,6 +868,10 @@ class CONTENT_EXPORT PepperPluginInstanceImpl
// The text that is currently selected in the plugin.
base::string16 selected_text_;
+ int64 last_input_number_;
+
+ bool is_tracking_latency_;
+
// We use a weak ptr factory for scheduling DidChangeView events so that we
// can tell whether updates are pending and consolidate them. When there's
// already a weak ptr pending (HasWeakPtrs is true), code should update the
« no previous file with comments | « content/renderer/pepper/pepper_graphics_2d_host_unittest.cc ('k') | content/renderer/pepper/pepper_plugin_instance_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698