Roll WebRTC 9189:9205, Libjingle 9186:9198
[chromium-blink-merge.git] / content / renderer / input / input_handler_proxy_client.h
blob66cd5aa6efa5f19afd4245eeb90de14202fcec05
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
3 // found in the LICENSE file.
5 #ifndef CONTENT_RENDERER_INPUT_INPUT_HANDLER_PROXY_CLIENT_H_
6 #define CONTENT_RENDERER_INPUT_INPUT_HANDLER_PROXY_CLIENT_H_
8 namespace blink {
9 class WebGestureCurve;
10 struct WebActiveWheelFlingParameters;
11 struct WebFloatPoint;
12 struct WebSize;
15 namespace content {
17 struct DidOverscrollParams;
19 // All callbacks invoked from the compositor thread.
20 class InputHandlerProxyClient {
21 public:
22 // Called just before the InputHandlerProxy shuts down.
23 virtual void WillShutdown() = 0;
25 // Transfers an active wheel fling animation initiated by a previously
26 // handled input event out to the client.
27 virtual void TransferActiveWheelFlingAnimation(
28 const blink::WebActiveWheelFlingParameters& params) = 0;
30 // Creates a new fling animation curve instance for device |device_source|
31 // with |velocity| and already scrolled |cumulative_scroll| pixels.
32 virtual blink::WebGestureCurve* CreateFlingAnimationCurve(
33 blink::WebGestureDevice device_source,
34 const blink::WebFloatPoint& velocity,
35 const blink::WebSize& cumulative_scroll) = 0;
37 virtual void DidOverscroll(const DidOverscrollParams& params) = 0;
39 virtual void DidStopFlinging() = 0;
41 virtual void DidReceiveInputEvent(
42 const blink::WebInputEvent& web_input_event) = 0;
44 virtual void DidAnimateForInput() = 0;
46 protected:
47 virtual ~InputHandlerProxyClient() {}
50 } // namespace content
52 #endif // CONTENT_RENDERER_INPUT_INPUT_HANDLER_PROXY_CLIENT_H_