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

Side by Side Diff: content/renderer/input/input_handler_manager.h

Issue 2094323002: Ensure acks are sent for all blocking events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix nits Created 4 years, 5 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_ 5 #ifndef CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_
6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_ 6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_
7 7
8 #include "base/containers/scoped_ptr_hash_map.h" 8 #include "base/containers/scoped_ptr_hash_map.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 60
61 void RegisterRoutingID(int routing_id); 61 void RegisterRoutingID(int routing_id);
62 void UnregisterRoutingID(int routing_id); 62 void UnregisterRoutingID(int routing_id);
63 63
64 void ObserveGestureEventAndResultOnMainThread( 64 void ObserveGestureEventAndResultOnMainThread(
65 int routing_id, 65 int routing_id,
66 const blink::WebGestureEvent& gesture_event, 66 const blink::WebGestureEvent& gesture_event,
67 const cc::InputHandlerScrollResult& scroll_result); 67 const cc::InputHandlerScrollResult& scroll_result);
68 68
69 void NotifyInputEventHandledOnMainThread(int routing_id, 69 void NotifyInputEventHandledOnMainThread(int routing_id,
70 blink::WebInputEvent::Type); 70 blink::WebInputEvent::Type,
71 InputEventAckState);
71 72
72 // Callback only from the compositor's thread. 73 // Callback only from the compositor's thread.
73 void RemoveInputHandler(int routing_id); 74 void RemoveInputHandler(int routing_id);
74 75
75 // Called from the compositor's thread. 76 // Called from the compositor's thread.
76 virtual InputEventAckState HandleInputEvent( 77 virtual InputEventAckState HandleInputEvent(
77 int routing_id, 78 int routing_id,
78 const blink::WebInputEvent* input_event, 79 const blink::WebInputEvent* input_event,
79 ui::LatencyInfo* latency_info); 80 ui::LatencyInfo* latency_info);
80 81
(...skipping 23 matching lines...) Expand all
104 int routing_id, 105 int routing_id,
105 const blink::WebMouseWheelEvent& wheel_event, 106 const blink::WebMouseWheelEvent& wheel_event,
106 const cc::InputHandlerScrollResult& scroll_result); 107 const cc::InputHandlerScrollResult& scroll_result);
107 108
108 void ObserveGestureEventAndResultOnCompositorThread( 109 void ObserveGestureEventAndResultOnCompositorThread(
109 int routing_id, 110 int routing_id,
110 const blink::WebGestureEvent& gesture_event, 111 const blink::WebGestureEvent& gesture_event,
111 const cc::InputHandlerScrollResult& scroll_result); 112 const cc::InputHandlerScrollResult& scroll_result);
112 113
113 void NotifyInputEventHandledOnCompositorThread(int routing_id, 114 void NotifyInputEventHandledOnCompositorThread(int routing_id,
114 blink::WebInputEvent::Type); 115 blink::WebInputEvent::Type,
116 InputEventAckState);
115 117
116 typedef base::ScopedPtrHashMap<int, // routing_id 118 typedef base::ScopedPtrHashMap<int, // routing_id
117 std::unique_ptr<InputHandlerWrapper>> 119 std::unique_ptr<InputHandlerWrapper>>
118 InputHandlerMap; 120 InputHandlerMap;
119 InputHandlerMap input_handlers_; 121 InputHandlerMap input_handlers_;
120 122
121 const scoped_refptr<base::SingleThreadTaskRunner> task_runner_; 123 const scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
122 InputHandlerManagerClient* const client_; 124 InputHandlerManagerClient* const client_;
123 // May be null. 125 // May be null.
124 SynchronousInputHandlerProxyClient* const synchronous_handler_proxy_client_; 126 SynchronousInputHandlerProxyClient* const synchronous_handler_proxy_client_;
125 scheduler::RendererScheduler* const renderer_scheduler_; // Not owned. 127 scheduler::RendererScheduler* const renderer_scheduler_; // Not owned.
126 }; 128 };
127 129
128 } // namespace content 130 } // namespace content
129 131
130 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_ 132 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698