Use multiline attribute to check for IA2_STATE_MULTILINE.
[chromium-blink-merge.git] / content / browser / renderer_host / input / input_router_client.h
blobdd3c6a0a3820b4661682c5e3dfe4ff1ea4508174
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_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_CLIENT_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_CLIENT_H_
8 #include "content/browser/renderer_host/event_with_latency_info.h"
9 #include "content/common/content_export.h"
10 #include "content/common/input/input_event_ack_state.h"
11 #include "content/public/browser/native_web_keyboard_event.h"
12 #include "third_party/WebKit/public/web/WebInputEvent.h"
14 namespace ui {
15 struct LatencyInfo;
18 namespace content {
20 struct DidOverscrollParams;
22 class CONTENT_EXPORT InputRouterClient {
23 public:
24 virtual ~InputRouterClient() {}
26 // Called just prior to events being sent to the renderer, giving the client
27 // a chance to perform in-process event filtering.
28 // The returned disposition will yield the following behavior:
29 // * |NOT_CONSUMED| will result in |input_event| being sent as usual.
30 // * |CONSUMED| or |NO_CONSUMER_EXISTS| will trigger the appropriate ack.
31 // * |UNKNOWN| will result in |input_event| being dropped.
32 virtual InputEventAckState FilterInputEvent(
33 const blink::WebInputEvent& input_event,
34 const ui::LatencyInfo& latency_info) = 0;
36 // Called each time a WebInputEvent IPC is sent.
37 virtual void IncrementInFlightEventCount() = 0;
39 // Called each time a WebInputEvent ACK IPC is received.
40 virtual void DecrementInFlightEventCount() = 0;
42 // Called when the renderer notifies that it has touch event handlers.
43 virtual void OnHasTouchEventHandlers(bool has_handlers) = 0;
45 // Called when the router has finished flushing all events queued at the time
46 // of the call to Flush. The call will typically be asynchronous with
47 // respect to the call to |Flush| on the InputRouter.
48 virtual void DidFlush() = 0;
50 // Called when the router has received an overscroll notification from the
51 // renderer.
52 virtual void DidOverscroll(const DidOverscrollParams& params) = 0;
54 // Called when a renderer fling has terminated.
55 virtual void DidStopFlinging() = 0;
58 } // namespace content
60 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_CLIENT_H_