| OLD | NEW |
| 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_CLIENT_H_ | 5 #ifndef CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_CLIENT_H_ |
| 6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_CLIENT_H_ | 6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_CLIENT_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/callback_forward.h" | 9 #include "base/callback_forward.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
| 12 #include "content/common/input/input_event_ack_state.h" | 12 #include "content/common/input/input_event_ack_state.h" |
| 13 #include "third_party/WebKit/public/platform/WebInputEvent.h" | 13 #include "third_party/WebKit/public/platform/WebCoalescedInputEvent.h" |
| 14 #include "ui/events/blink/scoped_web_input_event.h" | 14 #include "ui/events/blink/scoped_web_input_event.h" |
| 15 #include "ui/gfx/geometry/vector2d_f.h" | 15 #include "ui/gfx/geometry/vector2d_f.h" |
| 16 | 16 |
| 17 namespace ui { | 17 namespace ui { |
| 18 class LatencyInfo; | 18 class LatencyInfo; |
| 19 class SynchronousInputHandlerProxy; | 19 class SynchronousInputHandlerProxy; |
| 20 struct DidOverscrollParams; | 20 struct DidOverscrollParams; |
| 21 } | 21 } |
| 22 | 22 |
| 23 namespace content { | 23 namespace content { |
| (...skipping 15 matching lines...) Expand all Loading... |
| 39 virtual void UnregisterRoutingID(int routing_id) = 0; | 39 virtual void UnregisterRoutingID(int routing_id) = 0; |
| 40 | 40 |
| 41 // |HandleInputEvent| will respond to overscroll by calling the passed in | 41 // |HandleInputEvent| will respond to overscroll by calling the passed in |
| 42 // callback. | 42 // callback. |
| 43 // Otherwise |DidOverscroll| will be fired. | 43 // Otherwise |DidOverscroll| will be fired. |
| 44 virtual void DidOverscroll(int routing_id, | 44 virtual void DidOverscroll(int routing_id, |
| 45 const ui::DidOverscrollParams& params) = 0; | 45 const ui::DidOverscrollParams& params) = 0; |
| 46 virtual void DidStopFlinging(int routing_id) = 0; | 46 virtual void DidStopFlinging(int routing_id) = 0; |
| 47 virtual void DispatchNonBlockingEventToMainThread( | 47 virtual void DispatchNonBlockingEventToMainThread( |
| 48 int routing_id, | 48 int routing_id, |
| 49 ui::ScopedWebInputEvent event, | 49 blink::WebCoalescedInputEvent::ScopedWebInputEvent event, |
| 50 const ui::LatencyInfo& latency_info) = 0; | 50 const ui::LatencyInfo& latency_info) = 0; |
| 51 | 51 |
| 52 protected: | 52 protected: |
| 53 InputHandlerManagerClient() {} | 53 InputHandlerManagerClient() {} |
| 54 | 54 |
| 55 private: | 55 private: |
| 56 DISALLOW_COPY_AND_ASSIGN(InputHandlerManagerClient); | 56 DISALLOW_COPY_AND_ASSIGN(InputHandlerManagerClient); |
| 57 }; | 57 }; |
| 58 | 58 |
| 59 class CONTENT_EXPORT SynchronousInputHandlerProxyClient { | 59 class CONTENT_EXPORT SynchronousInputHandlerProxyClient { |
| 60 public: | 60 public: |
| 61 virtual ~SynchronousInputHandlerProxyClient() {} | 61 virtual ~SynchronousInputHandlerProxyClient() {} |
| 62 | 62 |
| 63 virtual void DidAddSynchronousHandlerProxy( | 63 virtual void DidAddSynchronousHandlerProxy( |
| 64 int routing_id, | 64 int routing_id, |
| 65 ui::SynchronousInputHandlerProxy* synchronous_handler) = 0; | 65 ui::SynchronousInputHandlerProxy* synchronous_handler) = 0; |
| 66 virtual void DidRemoveSynchronousHandlerProxy(int routing_id) = 0; | 66 virtual void DidRemoveSynchronousHandlerProxy(int routing_id) = 0; |
| 67 | 67 |
| 68 protected: | 68 protected: |
| 69 SynchronousInputHandlerProxyClient() {} | 69 SynchronousInputHandlerProxyClient() {} |
| 70 | 70 |
| 71 private: | 71 private: |
| 72 DISALLOW_COPY_AND_ASSIGN(SynchronousInputHandlerProxyClient); | 72 DISALLOW_COPY_AND_ASSIGN(SynchronousInputHandlerProxyClient); |
| 73 }; | 73 }; |
| 74 | 74 |
| 75 } // namespace content | 75 } // namespace content |
| 76 | 76 |
| 77 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_CLIENT_H_ | 77 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_MANAGER_CLIENT_H_ |
| OLD | NEW |