OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ | 5 #ifndef CONTENT_RENDERER_INPUT_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ |
6 #define CONTENT_RENDERER_INPUT_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ | 6 #define CONTENT_RENDERER_INPUT_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 | 63 |
64 // Call this if virtual keyboard should be displayed, e.g. after a tap on an | 64 // Call this if virtual keyboard should be displayed, e.g. after a tap on an |
65 // input field on mobile. Note that we do this just by setting a bit in | 65 // input field on mobile. Note that we do this just by setting a bit in |
66 // text input state and update it to the browser such that browser process can | 66 // text input state and update it to the browser such that browser process can |
67 // be up to date when showing virtual keyboard. | 67 // be up to date when showing virtual keyboard. |
68 virtual void ShowVirtualKeyboard() = 0; | 68 virtual void ShowVirtualKeyboard() = 0; |
69 | 69 |
70 // Send an update of text input state to the browser process. | 70 // Send an update of text input state to the browser process. |
71 virtual void UpdateTextInputState() = 0; | 71 virtual void UpdateTextInputState() = 0; |
72 | 72 |
| 73 // Called when a tap changes the current text selection (or keeps it the |
| 74 // same). Sends an IPC message to the InputHost if a menu displaying suggested |
| 75 // text replacements should be shown. |
| 76 virtual void HandlePotentialTextSuggestionTap() = 0; |
| 77 |
73 // Notifies that a gesture event is about to be handled. | 78 // Notifies that a gesture event is about to be handled. |
74 // Returns true if no further handling is needed. In that case, the event | 79 // Returns true if no further handling is needed. In that case, the event |
75 // won't be sent to WebKit. | 80 // won't be sent to WebKit. |
76 virtual bool WillHandleGestureEvent(const blink::WebGestureEvent& event) = 0; | 81 virtual bool WillHandleGestureEvent(const blink::WebGestureEvent& event) = 0; |
77 | 82 |
78 // Notifies that a mouse event is about to be handled. | 83 // Notifies that a mouse event is about to be handled. |
79 // Returns true if no further handling is needed. In that case, the event | 84 // Returns true if no further handling is needed. In that case, the event |
80 // won't be sent to WebKit or trigger DidHandleMouseEvent(). | 85 // won't be sent to WebKit or trigger DidHandleMouseEvent(). |
81 virtual bool WillHandleMouseEvent(const blink::WebMouseEvent& event) = 0; | 86 virtual bool WillHandleMouseEvent(const blink::WebMouseEvent& event) = 0; |
82 | 87 |
83 protected: | 88 protected: |
84 virtual ~RenderWidgetInputHandlerDelegate() {} | 89 virtual ~RenderWidgetInputHandlerDelegate() {} |
85 }; | 90 }; |
86 | 91 |
87 } // namespace content | 92 } // namespace content |
88 | 93 |
89 #endif // CONTENT_RENDERER_INPUT_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ | 94 #endif // CONTENT_RENDERER_INPUT_RENDER_WIDGET_INPUT_HANDLER_DELEGATE_H_ |
OLD | NEW |