| 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 529 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 540 // Called by the browser process to update the cursor and composition | 540 // Called by the browser process to update the cursor and composition |
| 541 // information. | 541 // information. |
| 542 void OnRequestCompositionUpdate(bool immediate_request, bool monitor_request); | 542 void OnRequestCompositionUpdate(bool immediate_request, bool monitor_request); |
| 543 | 543 |
| 544 // Notify the compositor about a change in viewport size. This should be | 544 // Notify the compositor about a change in viewport size. This should be |
| 545 // used only with auto resize mode WebWidgets, as normal WebWidgets should | 545 // used only with auto resize mode WebWidgets, as normal WebWidgets should |
| 546 // go through OnResize. | 546 // go through OnResize. |
| 547 void AutoResizeCompositor(); | 547 void AutoResizeCompositor(); |
| 548 | 548 |
| 549 virtual void OnSetDeviceScaleFactor(float device_scale_factor); | 549 virtual void OnSetDeviceScaleFactor(float device_scale_factor); |
| 550 bool SetDeviceColorProfile(const std::vector<char>& color_profile); | |
| 551 | 550 |
| 552 virtual void OnOrientationChange(); | 551 virtual void OnOrientationChange(); |
| 553 | 552 |
| 554 // Override points to notify derived classes that a paint has happened. | 553 // Override points to notify derived classes that a paint has happened. |
| 555 // DidInitiatePaint happens when that has completed, and subsequent rendering | 554 // DidInitiatePaint happens when that has completed, and subsequent rendering |
| 556 // won't affect the painted content. | 555 // won't affect the painted content. |
| 557 virtual void DidInitiatePaint() {} | 556 virtual void DidInitiatePaint() {} |
| 558 | 557 |
| 559 virtual GURL GetURLForGraphicsContext3D(); | 558 virtual GURL GetURLForGraphicsContext3D(); |
| 560 | 559 |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 738 // The time spent in input handlers this frame. Used to throttle input acks. | 737 // The time spent in input handlers this frame. Used to throttle input acks. |
| 739 base::TimeDelta total_input_handling_time_this_frame_; | 738 base::TimeDelta total_input_handling_time_this_frame_; |
| 740 | 739 |
| 741 // Properties of the screen hosting this RenderWidget instance. | 740 // Properties of the screen hosting this RenderWidget instance. |
| 742 ScreenInfo screen_info_; | 741 ScreenInfo screen_info_; |
| 743 | 742 |
| 744 // The device scale factor. This value is computed from the DPI entries in | 743 // The device scale factor. This value is computed from the DPI entries in |
| 745 // |screen_info_| on some platforms, and defaults to 1 on other platforms. | 744 // |screen_info_| on some platforms, and defaults to 1 on other platforms. |
| 746 float device_scale_factor_; | 745 float device_scale_factor_; |
| 747 | 746 |
| 748 // The device color profile on supported platforms. | |
| 749 std::vector<char> device_color_profile_; | |
| 750 | |
| 751 // State associated with synthetic gestures. Synthetic gestures are processed | 747 // State associated with synthetic gestures. Synthetic gestures are processed |
| 752 // in-order, so a queue is sufficient to identify the correct state for a | 748 // in-order, so a queue is sufficient to identify the correct state for a |
| 753 // completed gesture. | 749 // completed gesture. |
| 754 std::queue<SyntheticGestureCompletionCallback> | 750 std::queue<SyntheticGestureCompletionCallback> |
| 755 pending_synthetic_gesture_callbacks_; | 751 pending_synthetic_gesture_callbacks_; |
| 756 | 752 |
| 757 // True if the IME requests updated composition info. | 753 // True if the IME requests updated composition info. |
| 758 bool monitor_composition_info_; | 754 bool monitor_composition_info_; |
| 759 | 755 |
| 760 std::unique_ptr<RenderWidgetScreenMetricsEmulator> screen_metrics_emulator_; | 756 std::unique_ptr<RenderWidgetScreenMetricsEmulator> screen_metrics_emulator_; |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 836 // being handled. If the current event results in starting a drag/drop | 832 // being handled. If the current event results in starting a drag/drop |
| 837 // session, this info is sent to the browser along with other drag/drop info. | 833 // session, this info is sent to the browser along with other drag/drop info. |
| 838 DragEventSourceInfo possible_drag_event_info_; | 834 DragEventSourceInfo possible_drag_event_info_; |
| 839 | 835 |
| 840 DISALLOW_COPY_AND_ASSIGN(RenderWidget); | 836 DISALLOW_COPY_AND_ASSIGN(RenderWidget); |
| 841 }; | 837 }; |
| 842 | 838 |
| 843 } // namespace content | 839 } // namespace content |
| 844 | 840 |
| 845 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ | 841 #endif // CONTENT_RENDERER_RENDER_WIDGET_H_ |
| OLD | NEW |