Chromium Code Reviews| Index: content/browser/renderer_host/input/input_router_impl.cc |
| diff --git a/content/browser/renderer_host/input/input_router_impl.cc b/content/browser/renderer_host/input/input_router_impl.cc |
| index 441f9384bb8745e05efd53d9e1e645aa94255124..451d87bb5d10878741af41ab7cdb23ff841ae13b 100644 |
| --- a/content/browser/renderer_host/input/input_router_impl.cc |
| +++ b/content/browser/renderer_host/input/input_router_impl.cc |
| @@ -10,6 +10,7 @@ |
| #include "base/command_line.h" |
| #include "base/metrics/histogram.h" |
| #include "base/strings/string_number_conversions.h" |
| +#include "content/browser/gpu/gpu_process_host.h" |
| #include "content/browser/renderer_host/input/gesture_event_queue.h" |
| #include "content/browser/renderer_host/input/input_ack_handler.h" |
| #include "content/browser/renderer_host/input/input_router_client.h" |
| @@ -17,6 +18,7 @@ |
| #include "content/browser/renderer_host/input/touchpad_tap_suppression_controller.h" |
| #include "content/common/content_constants_internal.h" |
| #include "content/common/edit_command.h" |
| +#include "content/common/gpu/gpu_messages.h" |
| #include "content/common/input/input_event_ack_state.h" |
| #include "content/common/input/touch_action.h" |
| #include "content/common/input/web_touch_event_traits.h" |
| @@ -347,6 +349,7 @@ void InputRouterImpl::OfferToHandlers(const WebInputEvent& input_event, |
| if (OfferToClient(input_event, latency_info)) |
| return; |
| + OfferToGpuService(input_event, is_keyboard_shortcut); |
| OfferToRenderer(input_event, latency_info, is_keyboard_shortcut); |
| // Touch events should always indicate in the event whether they are |
| @@ -409,6 +412,18 @@ bool InputRouterImpl::OfferToRenderer(const WebInputEvent& input_event, |
| return false; |
| } |
| +void InputRouterImpl::OfferToGpuService(const blink::WebInputEvent& input_event, |
| + bool is_keyboard_shortcut) { |
| + GpuProcessHost::SendOnIO( |
| +#if defined(OS_WIN) |
| + GpuProcessHost::GPU_PROCESS_KIND_UNSANDBOXED, |
|
jdduke (slow)
2014/10/13 17:14:45
Is the GPU service interested in all event types?
orglofch
2014/10/13 17:30:26
Only mouse events right now. I can't think of a us
|
| +#else |
| + GpuProcessHost::GPU_PROCESS_KIND_SANDBOXED, |
| +#endif |
| + CAUSE_FOR_GPU_LAUNCH_NO_LAUNCH, |
| + new GpuMsg_HandleInputEvent(&input_event, is_keyboard_shortcut)); |
| +} |
| + |
| void InputRouterImpl::SendSyntheticWheelEventForPinch( |
| const GestureEventWithLatencyInfo& pinch_event) { |
| // We match typical trackpad behavior on Windows by sending fake wheel events |