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

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

Issue 2663283002: scheduler: Detect single event gestures correctly (Closed)
Patch Set: Fix test build failure Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_MAIN_THREAD_EVENT_QUEUE_H_ 5 #ifndef CONTENT_RENDERER_INPUT_MAIN_THREAD_EVENT_QUEUE_H_
6 #define CONTENT_RENDERER_INPUT_MAIN_THREAD_EVENT_QUEUE_H_ 6 #define CONTENT_RENDERER_INPUT_MAIN_THREAD_EVENT_QUEUE_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include "base/feature_list.h" 9 #include "base/feature_list.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 // a non-blocking event to be queued to the main thread. 122 // a non-blocking event to be queued to the main thread.
123 bool HandleEvent(blink::WebScopedInputEvent event, 123 bool HandleEvent(blink::WebScopedInputEvent event,
124 const ui::LatencyInfo& latency, 124 const ui::LatencyInfo& latency,
125 InputEventDispatchType dispatch_type, 125 InputEventDispatchType dispatch_type,
126 InputEventAckState ack_result); 126 InputEventAckState ack_result);
127 void DispatchRafAlignedInput(); 127 void DispatchRafAlignedInput();
128 128
129 // Call once the main thread has handled an outstanding |type| event 129 // Call once the main thread has handled an outstanding |type| event
130 // in flight. 130 // in flight.
131 void EventHandled(blink::WebInputEvent::Type type, 131 void EventHandled(blink::WebInputEvent::Type type,
132 blink::WebInputEventResult result,
132 InputEventAckState ack_result); 133 InputEventAckState ack_result);
133 134
134 private: 135 private:
135 friend class base::RefCountedThreadSafe<MainThreadEventQueue>; 136 friend class base::RefCountedThreadSafe<MainThreadEventQueue>;
136 ~MainThreadEventQueue(); 137 ~MainThreadEventQueue();
137 void QueueEvent(std::unique_ptr<EventWithDispatchType> event); 138 void QueueEvent(std::unique_ptr<EventWithDispatchType> event);
138 void SendEventNotificationToMainThread(); 139 void SendEventNotificationToMainThread();
139 void DispatchSingleEvent(); 140 void DispatchSingleEvent();
140 void DispatchInFlightEvent(); 141 void DispatchInFlightEvent();
141 void PossiblyScheduleMainFrame(); 142 void PossiblyScheduleMainFrame();
(...skipping 30 matching lines...) Expand all
172 173
173 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner_; 174 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner_;
174 blink::scheduler::RendererScheduler* renderer_scheduler_; 175 blink::scheduler::RendererScheduler* renderer_scheduler_;
175 176
176 DISALLOW_COPY_AND_ASSIGN(MainThreadEventQueue); 177 DISALLOW_COPY_AND_ASSIGN(MainThreadEventQueue);
177 }; 178 };
178 179
179 } // namespace content 180 } // namespace content
180 181
181 #endif // CONTENT_RENDERER_INPUT_MAIN_THREAD_EVENT_QUEUE_H_ 182 #endif // CONTENT_RENDERER_INPUT_MAIN_THREAD_EVENT_QUEUE_H_
OLDNEW
« no previous file with comments | « content/renderer/input/input_handler_manager_client.h ('k') | content/renderer/input/main_thread_event_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698