Index: content/browser/renderer_host/input/render_widget_host_latency_tracker.h |
diff --git a/content/browser/renderer_host/input/render_widget_host_latency_tracker.h b/content/browser/renderer_host/input/render_widget_host_latency_tracker.h |
index 633e4e878da43bb4097739ec8f934ec3c227ffd9..0363e31d8d264c76a2193f884b38e1c7a5b3fdb5 100644 |
--- a/content/browser/renderer_host/input/render_widget_host_latency_tracker.h |
+++ b/content/browser/renderer_host/input/render_widget_host_latency_tracker.h |
@@ -60,11 +60,18 @@ class CONTENT_EXPORT RenderWidgetHostLatencyTracker { |
// subsystem. |
int64_t latency_component_id() const { return latency_component_id_; } |
+ // Add/remove a callback that can handle input events routed to latency |
+ // tracker. |
+ typedef base::Callback<bool(const blink::WebInputEvent&)> InputEventCallback; |
+ void AddInputEventCallback(const InputEventCallback& callback); |
+ void RemoveInputEventCallback(const InputEventCallback& callback); |
+ |
private: |
int64_t last_event_id_; |
int64_t latency_component_id_; |
float device_scale_factor_; |
bool has_seen_first_gesture_scroll_update_; |
+ std::vector<InputEventCallback> input_event_callbacks_; |
Bryan McQuade
2016/05/25 21:32:30
can you use base::ObserverList here? the comments
|
DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostLatencyTracker); |
}; |