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 <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 // will not be automatically available to BrowserMessageFilter, for example. | 298 // will not be automatically available to BrowserMessageFilter, for example. |
299 // FIFO ordering is preserved between messages enqueued with the same | 299 // FIFO ordering is preserved between messages enqueued with the same |
300 // |policy|, the ordering between messages enqueued for different policies is | 300 // |policy|, the ordering between messages enqueued for different policies is |
301 // undefined. | 301 // undefined. |
302 // | 302 // |
303 // |msg| message to send, ownership of |msg| is transferred. | 303 // |msg| message to send, ownership of |msg| is transferred. |
304 // |policy| see the comment on MessageDeliveryPolicy. | 304 // |policy| see the comment on MessageDeliveryPolicy. |
305 void QueueMessage(IPC::Message* msg, MessageDeliveryPolicy policy); | 305 void QueueMessage(IPC::Message* msg, MessageDeliveryPolicy policy); |
306 | 306 |
307 // Handle start and finish of IME event guard. | 307 // Handle start and finish of IME event guard. |
| 308 bool IsFromImeDefault(); |
308 void OnImeEventGuardStart(ImeEventGuard* guard); | 309 void OnImeEventGuardStart(ImeEventGuard* guard); |
309 void OnImeEventGuardFinish(ImeEventGuard* guard); | 310 void OnImeEventGuardFinish(ImeEventGuard* guard); |
310 | 311 |
311 // Returns whether we currently should handle an IME event. | 312 // Returns whether we currently should handle an IME event. |
312 bool ShouldHandleImeEvent(); | 313 bool ShouldHandleImeEvent(); |
313 | 314 |
314 // ScreenMetricsEmulator class manages screen emulation inside a render | 315 // ScreenMetricsEmulator class manages screen emulation inside a render |
315 // widget. This includes resizing, placing view on the screen at desired | 316 // widget. This includes resizing, placing view on the screen at desired |
316 // position, changing device scale factor, and scaling down the whole | 317 // position, changing device scale factor, and scaling down the whole |
317 // widget if required to fit into the browser window. | 318 // widget if required to fit into the browser window. |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
453 void OnShowImeIfNeeded(); | 454 void OnShowImeIfNeeded(); |
454 void OnSetSurfaceIdNamespace(uint32_t surface_id_namespace); | 455 void OnSetSurfaceIdNamespace(uint32_t surface_id_namespace); |
455 void OnHandleCompositorProto(const std::vector<uint8_t>& proto); | 456 void OnHandleCompositorProto(const std::vector<uint8_t>& proto); |
456 | 457 |
457 #if defined(OS_ANDROID) | 458 #if defined(OS_ANDROID) |
458 // Called when we send IME event that expects an ACK. | 459 // Called when we send IME event that expects an ACK. |
459 void OnImeEventSentForAck(const blink::WebTextInputInfo& info); | 460 void OnImeEventSentForAck(const blink::WebTextInputInfo& info); |
460 | 461 |
461 // Called by the browser process for every required IME acknowledgement. | 462 // Called by the browser process for every required IME acknowledgement. |
462 void OnImeEventAck(); | 463 void OnImeEventAck(); |
| 464 |
| 465 // Called by the browser process to update text input state. |
| 466 void OnRequestTextInputStateUpdate(); |
463 #endif | 467 #endif |
464 | 468 |
465 // Notify the compositor about a change in viewport size. This should be | 469 // Notify the compositor about a change in viewport size. This should be |
466 // used only with auto resize mode WebWidgets, as normal WebWidgets should | 470 // used only with auto resize mode WebWidgets, as normal WebWidgets should |
467 // go through OnResize. | 471 // go through OnResize. |
468 void AutoResizeCompositor(); | 472 void AutoResizeCompositor(); |
469 | 473 |
470 virtual void SetDeviceScaleFactor(float device_scale_factor); | 474 virtual void SetDeviceScaleFactor(float device_scale_factor); |
471 virtual bool SetDeviceColorProfile(const std::vector<char>& color_profile); | 475 virtual bool SetDeviceColorProfile(const std::vector<char>& color_profile); |
472 virtual void ResetDeviceColorProfileForTesting(); | 476 virtual void ResetDeviceColorProfileForTesting(); |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
753 | 757 |
754 scoped_ptr<scheduler::RenderWidgetSchedulingState> | 758 scoped_ptr<scheduler::RenderWidgetSchedulingState> |
755 render_widget_scheduling_state_; | 759 render_widget_scheduling_state_; |
756 | 760 |
757 DISALLOW_COPY_AND_ASSIGN(RenderWidget); | 761 DISALLOW_COPY_AND_ASSIGN(RenderWidget); |
758 }; | 762 }; |
759 | 763 |
760 } // namespace content | 764 } // namespace content |
761 | 765 |
762 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ | 766 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ |
OLD | NEW |