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_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 struct DidOverscrollParams; | 64 struct DidOverscrollParams; |
65 struct NativeWebKeyboardEvent; | 65 struct NativeWebKeyboardEvent; |
66 struct WebPluginGeometry; | 66 struct WebPluginGeometry; |
67 | 67 |
68 // Basic implementation shared by concrete RenderWidgetHostView subclasses. | 68 // Basic implementation shared by concrete RenderWidgetHostView subclasses. |
69 class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView, | 69 class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView, |
70 public IPC::Listener { | 70 public IPC::Listener { |
71 public: | 71 public: |
72 ~RenderWidgetHostViewBase() override; | 72 ~RenderWidgetHostViewBase() override; |
73 | 73 |
| 74 float current_device_scale_factor() const { |
| 75 return current_device_scale_factor_; |
| 76 } |
| 77 |
74 // RenderWidgetHostView implementation. | 78 // RenderWidgetHostView implementation. |
75 void SetBackgroundColor(SkColor color) override; | 79 void SetBackgroundColor(SkColor color) override; |
76 void SetBackgroundColorToDefault() final; | 80 void SetBackgroundColorToDefault() final; |
77 bool GetBackgroundOpaque() override; | 81 bool GetBackgroundOpaque() override; |
78 ui::TextInputClient* GetTextInputClient() override; | 82 ui::TextInputClient* GetTextInputClient() override; |
79 void WasUnOccluded() override {} | 83 void WasUnOccluded() override {} |
80 void WasOccluded() override {} | 84 void WasOccluded() override {} |
81 bool IsShowingContextMenu() const override; | 85 bool IsShowingContextMenu() const override; |
82 void SetShowingContextMenu(bool showing_menu) override; | 86 void SetShowingContextMenu(bool showing_menu) override; |
83 base::string16 GetSelectedText() const override; | 87 base::string16 GetSelectedText() const override; |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
448 base::OneShotTimer flush_input_timer_; | 452 base::OneShotTimer flush_input_timer_; |
449 | 453 |
450 base::WeakPtrFactory<RenderWidgetHostViewBase> weak_factory_; | 454 base::WeakPtrFactory<RenderWidgetHostViewBase> weak_factory_; |
451 | 455 |
452 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase); | 456 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase); |
453 }; | 457 }; |
454 | 458 |
455 } // namespace content | 459 } // namespace content |
456 | 460 |
457 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ | 461 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ |
OLD | NEW |