Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1024)

Side by Side Diff: content/browser/renderer_host/render_widget_host_delegate.h

Issue 1652483002: Browser Side Text Input State Tracking for OOPIF. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merged Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 13 matching lines...) Expand all
24 class Point; 24 class Point;
25 class Rect; 25 class Rect;
26 class Size; 26 class Size;
27 } 27 }
28 28
29 namespace content { 29 namespace content {
30 30
31 class BrowserAccessibilityManager; 31 class BrowserAccessibilityManager;
32 class RenderWidgetHostImpl; 32 class RenderWidgetHostImpl;
33 class RenderWidgetHostInputEventRouter; 33 class RenderWidgetHostInputEventRouter;
34 class RenderWidgetHostViewBase;
34 struct NativeWebKeyboardEvent; 35 struct NativeWebKeyboardEvent;
36 struct TextInputState;
35 37
36 // 38 //
37 // RenderWidgetHostDelegate 39 // RenderWidgetHostDelegate
38 // 40 //
39 // An interface implemented by an object interested in knowing about the state 41 // An interface implemented by an object interested in knowing about the state
40 // of the RenderWidgetHost. 42 // of the RenderWidgetHost.
41 class CONTENT_EXPORT RenderWidgetHostDelegate { 43 class CONTENT_EXPORT RenderWidgetHostDelegate {
42 public: 44 public:
43 // The RenderWidgetHost has just been created. 45 // The RenderWidgetHost has just been created.
44 virtual void RenderWidgetCreated(RenderWidgetHostImpl* render_widget_host) {} 46 virtual void RenderWidgetCreated(RenderWidgetHostImpl* render_widget_host) {}
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // RenderWidgetHost to this function to determine who should ultimately 127 // RenderWidgetHost to this function to determine who should ultimately
126 // consume the event. This facilitates keyboard event routing with 128 // consume the event. This facilitates keyboard event routing with
127 // out-of-process iframes, where multiple RenderWidgetHosts may be involved 129 // out-of-process iframes, where multiple RenderWidgetHosts may be involved
128 // in rendering a page, yet keyboard events all arrive at the main frame's 130 // in rendering a page, yet keyboard events all arrive at the main frame's
129 // RenderWidgetHostView. When a main frame's RenderWidgetHost is passed in, 131 // RenderWidgetHostView. When a main frame's RenderWidgetHost is passed in,
130 // the function returns the focused frame that should consume keyboard 132 // the function returns the focused frame that should consume keyboard
131 // events. In all other cases, the function returns back |receiving_widget|. 133 // events. In all other cases, the function returns back |receiving_widget|.
132 virtual RenderWidgetHostImpl* GetFocusedRenderWidgetHost( 134 virtual RenderWidgetHostImpl* GetFocusedRenderWidgetHost(
133 RenderWidgetHostImpl* receiving_widget); 135 RenderWidgetHostImpl* receiving_widget);
134 136
137 // Returns the current value of text input state. This should be the value
138 // obtained from the focused RWHV.
139 virtual const TextInputState* GetTextInputState();
140
141 // This method is called by any RWHV which receives an IPC regarding a change
142 // in the text input state. The IPC might or might not have lead to a change
143 // in state but this method must be called for IME related logic.
144 virtual void UpdateTextInputState(RenderWidgetHostViewBase* rwhv,
145 bool text_input_state_changed) {}
146
135 // Notification that the renderer has become unresponsive. The 147 // Notification that the renderer has become unresponsive. The
136 // delegate can use this notification to show a warning to the user. 148 // delegate can use this notification to show a warning to the user.
137 virtual void RendererUnresponsive(RenderWidgetHostImpl* render_widget_host) {} 149 virtual void RendererUnresponsive(RenderWidgetHostImpl* render_widget_host) {}
138 150
139 // Notification that a previously unresponsive renderer has become 151 // Notification that a previously unresponsive renderer has become
140 // responsive again. The delegate can use this notification to end the 152 // responsive again. The delegate can use this notification to end the
141 // warning shown to the user. 153 // warning shown to the user.
142 virtual void RendererResponsive(RenderWidgetHostImpl* render_widget_host) {} 154 virtual void RendererResponsive(RenderWidgetHostImpl* render_widget_host) {}
143 155
144 // Requests to lock the mouse. Once the request is approved or rejected, 156 // Requests to lock the mouse. Once the request is approved or rejected,
(...skipping 15 matching lines...) Expand all
160 // Returns the display mode for the view. 172 // Returns the display mode for the view.
161 virtual blink::WebDisplayMode GetDisplayMode( 173 virtual blink::WebDisplayMode GetDisplayMode(
162 RenderWidgetHostImpl* render_widget_host) const; 174 RenderWidgetHostImpl* render_widget_host) const;
163 175
164 // Notification that the widget has lost capture. 176 // Notification that the widget has lost capture.
165 virtual void LostCapture(RenderWidgetHostImpl* render_widget_host) {} 177 virtual void LostCapture(RenderWidgetHostImpl* render_widget_host) {}
166 178
167 // Notification that the widget has lost the mouse lock. 179 // Notification that the widget has lost the mouse lock.
168 virtual void LostMouseLock(RenderWidgetHostImpl* render_widget_host) {} 180 virtual void LostMouseLock(RenderWidgetHostImpl* render_widget_host) {}
169 181
170 // Called when the widget has sent a compositor proto. This is used in Btlimp 182 // Called when the widget has sent a compositor proto. This is used in Blimp
171 // mode with the RemoteChannel compositor. 183 // mode with the RemoteChannel compositor.
172 virtual void ForwardCompositorProto(RenderWidgetHostImpl* render_widget_host, 184 virtual void ForwardCompositorProto(RenderWidgetHostImpl* render_widget_host,
173 const std::vector<uint8_t>& proto) {} 185 const std::vector<uint8_t>& proto) {}
174 186
175 // Called when the visibility of the RenderFrameProxyHost in outter 187 // Called when the visibility of the RenderFrameProxyHost in outer
176 // WebContents changes. This method is only called on an inner WebContents and 188 // WebContents changes. This method is only called on an inner WebContents and
177 // will eventually notify all the RenderWidgetHostViews belonging to that 189 // will eventually notify all the RenderWidgetHostViews belonging to that
178 // WebContents. 190 // WebContents.
179 virtual void OnRenderFrameProxyVisibilityChanged(bool visible) {} 191 virtual void OnRenderFrameProxyVisibilityChanged(bool visible) {}
180 192
181 // Update the renderer's cache of the screen rect of the view and window. 193 // Update the renderer's cache of the screen rect of the view and window.
182 virtual void SendScreenRects() {} 194 virtual void SendScreenRects() {}
183 195
184 protected: 196 protected:
185 virtual ~RenderWidgetHostDelegate() {} 197 virtual ~RenderWidgetHostDelegate() {}
186 }; 198 };
187 199
188 } // namespace content 200 } // namespace content
189 201
190 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_ 202 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698