OLD | NEW |
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_RENDERER_RENDER_WIDGET_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_WIDGET_H_ |
6 #define CONTENT_RENDERER_RENDER_WIDGET_H_ | 6 #define CONTENT_RENDERER_RENDER_WIDGET_H_ |
7 | 7 |
8 #include <deque> | 8 #include <deque> |
9 #include <map> | 9 #include <map> |
10 | 10 |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
225 void FinishHandlingImeEvent(); | 225 void FinishHandlingImeEvent(); |
226 | 226 |
227 // Returns whether we currently should handle an IME event. | 227 // Returns whether we currently should handle an IME event. |
228 bool ShouldHandleImeEvent(); | 228 bool ShouldHandleImeEvent(); |
229 | 229 |
230 virtual void InstrumentWillBeginFrame(int frame_id) {} | 230 virtual void InstrumentWillBeginFrame(int frame_id) {} |
231 virtual void InstrumentDidBeginFrame() {} | 231 virtual void InstrumentDidBeginFrame() {} |
232 virtual void InstrumentDidCancelFrame() {} | 232 virtual void InstrumentDidCancelFrame() {} |
233 virtual void InstrumentWillComposite() {} | 233 virtual void InstrumentWillComposite() {} |
234 | 234 |
| 235 // Called by the compositor when page scale animation completed. |
| 236 virtual void DidCompletePageScaleAnimation() {} |
| 237 |
235 // When paused in debugger, we send ack for mouse event early. This ensures | 238 // When paused in debugger, we send ack for mouse event early. This ensures |
236 // that we continue receiving mouse moves and pass them to debugger. Returns | 239 // that we continue receiving mouse moves and pass them to debugger. Returns |
237 // whether we are paused in mouse move event and have sent the ack. | 240 // whether we are paused in mouse move event and have sent the ack. |
238 bool SendAckForMouseMoveFromDebugger(); | 241 bool SendAckForMouseMoveFromDebugger(); |
239 | 242 |
240 // When resumed from pause in debugger while handling mouse move, | 243 // When resumed from pause in debugger while handling mouse move, |
241 // we should not send an extra ack (see SendAckForMouseMoveFromDebugger). | 244 // we should not send an extra ack (see SendAckForMouseMoveFromDebugger). |
242 void IgnoreAckForMouseMoveFromDebugger(); | 245 void IgnoreAckForMouseMoveFromDebugger(); |
243 | 246 |
244 // ScreenMetricsEmulator class manages screen emulation inside a render | 247 // ScreenMetricsEmulator class manages screen emulation inside a render |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 | 291 |
289 // |show_ime| should be SHOW_IME_IF_NEEDED iff the update may cause the ime to | 292 // |show_ime| should be SHOW_IME_IF_NEEDED iff the update may cause the ime to |
290 // be displayed, e.g. after a tap on an input field on mobile. | 293 // be displayed, e.g. after a tap on an input field on mobile. |
291 // |change_source| should be FROM_NON_IME when the renderer has to wait for | 294 // |change_source| should be FROM_NON_IME when the renderer has to wait for |
292 // the browser to acknowledge the change before the renderer handles any more | 295 // the browser to acknowledge the change before the renderer handles any more |
293 // IME events. This is when the text change did not originate from the IME in | 296 // IME events. This is when the text change did not originate from the IME in |
294 // the browser side, such as changes by JavaScript or autofill. | 297 // the browser side, such as changes by JavaScript or autofill. |
295 void UpdateTextInputState(ShowIme show_ime, ChangeSource change_source); | 298 void UpdateTextInputState(ShowIme show_ime, ChangeSource change_source); |
296 #endif | 299 #endif |
297 | 300 |
| 301 virtual void FocusChangeComplete() {} |
| 302 |
298 // Checks if the composition range or composition character bounds have been | 303 // Checks if the composition range or composition character bounds have been |
299 // changed. If they are changed, the new value will be sent to the browser | 304 // changed. If they are changed, the new value will be sent to the browser |
300 // process. This method does nothing when the browser process is not able to | 305 // process. This method does nothing when the browser process is not able to |
301 // handle composition range and composition character bounds. | 306 // handle composition range and composition character bounds. |
302 void UpdateCompositionInfo(bool should_update_range); | 307 void UpdateCompositionInfo(bool should_update_range); |
303 | 308 |
304 #if defined(OS_ANDROID) | 309 #if defined(OS_ANDROID) |
305 void DidChangeBodyBackgroundColor(SkColor bg_color); | 310 void DidChangeBodyBackgroundColor(SkColor bg_color); |
306 bool DoesRecordFullLayer() const; | 311 bool DoesRecordFullLayer() const; |
307 #endif | 312 #endif |
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
779 ui::MenuSourceType context_menu_source_type_; | 784 ui::MenuSourceType context_menu_source_type_; |
780 bool has_host_context_menu_location_; | 785 bool has_host_context_menu_location_; |
781 gfx::Point host_context_menu_location_; | 786 gfx::Point host_context_menu_location_; |
782 | 787 |
783 DISALLOW_COPY_AND_ASSIGN(RenderWidget); | 788 DISALLOW_COPY_AND_ASSIGN(RenderWidget); |
784 }; | 789 }; |
785 | 790 |
786 } // namespace content | 791 } // namespace content |
787 | 792 |
788 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ | 793 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ |
OLD | NEW |