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_PROXY_CLIENT_H_ | 5 #ifndef UI_EVENTS_BLINK_INPUT_HANDLER_PROXY_CLIENT_H_ |
6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_PROXY_CLIENT_H_ | 6 #define UI_EVENTS_BLINK_INPUT_HANDLER_PROXY_CLIENT_H_ |
7 | 7 |
8 namespace blink { | 8 namespace blink { |
9 class WebGestureCurve; | 9 class WebGestureCurve; |
10 struct WebActiveWheelFlingParameters; | 10 struct WebActiveWheelFlingParameters; |
11 struct WebFloatPoint; | 11 struct WebFloatPoint; |
12 struct WebSize; | 12 struct WebSize; |
13 } | 13 } |
14 | 14 |
15 namespace content { | 15 namespace ui { |
16 | |
17 struct DidOverscrollParams; | |
18 | 16 |
19 // All callbacks invoked from the compositor thread. | 17 // All callbacks invoked from the compositor thread. |
20 class InputHandlerProxyClient { | 18 class InputHandlerProxyClient { |
21 public: | 19 public: |
22 // Called just before the InputHandlerProxy shuts down. | 20 // Called just before the InputHandlerProxy shuts down. |
23 virtual void WillShutdown() = 0; | 21 virtual void WillShutdown() = 0; |
24 | 22 |
25 // Transfers an active wheel fling animation initiated by a previously | 23 // Transfers an active wheel fling animation initiated by a previously |
26 // handled input event out to the client. | 24 // handled input event out to the client. |
27 virtual void TransferActiveWheelFlingAnimation( | 25 virtual void TransferActiveWheelFlingAnimation( |
28 const blink::WebActiveWheelFlingParameters& params) = 0; | 26 const blink::WebActiveWheelFlingParameters& params) = 0; |
29 | 27 |
30 // Creates a new fling animation curve instance for device |device_source| | 28 // Creates a new fling animation curve instance for device |device_source| |
31 // with |velocity| and already scrolled |cumulative_scroll| pixels. | 29 // with |velocity| and already scrolled |cumulative_scroll| pixels. |
32 virtual blink::WebGestureCurve* CreateFlingAnimationCurve( | 30 virtual blink::WebGestureCurve* CreateFlingAnimationCurve( |
33 blink::WebGestureDevice device_source, | 31 blink::WebGestureDevice device_source, |
34 const blink::WebFloatPoint& velocity, | 32 const blink::WebFloatPoint& velocity, |
35 const blink::WebSize& cumulative_scroll) = 0; | 33 const blink::WebSize& cumulative_scroll) = 0; |
36 | 34 |
37 virtual void DidOverscroll(const DidOverscrollParams& params) = 0; | 35 virtual void DidOverscroll( |
| 36 const gfx::Vector2dF& accumulated_overscroll, |
| 37 const gfx::Vector2dF& latest_overscroll_delta, |
| 38 const gfx::Vector2dF& current_fling_velocity, |
| 39 const gfx::PointF& causal_event_viewport_point) = 0; |
38 | 40 |
39 virtual void DidStopFlinging() = 0; | 41 virtual void DidStopFlinging() = 0; |
40 | 42 |
41 virtual void DidAnimateForInput() = 0; | 43 virtual void DidAnimateForInput() = 0; |
42 | 44 |
43 protected: | 45 protected: |
44 virtual ~InputHandlerProxyClient() {} | 46 virtual ~InputHandlerProxyClient() {} |
45 }; | 47 }; |
46 | 48 |
47 } // namespace content | 49 } // namespace ui |
48 | 50 |
49 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_PROXY_CLIENT_H_ | 51 #endif // UI_EVENTS_BLINK_INPUT_HANDLER_PROXY_CLIENT_H_ |
OLD | NEW |