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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 struct DidOverscrollParams; | 68 struct DidOverscrollParams; |
69 struct NativeWebKeyboardEvent; | 69 struct NativeWebKeyboardEvent; |
70 struct WebPluginGeometry; | 70 struct WebPluginGeometry; |
71 | 71 |
72 // Basic implementation shared by concrete RenderWidgetHostView subclasses. | 72 // Basic implementation shared by concrete RenderWidgetHostView subclasses. |
73 class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView, | 73 class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView, |
74 public IPC::Listener { | 74 public IPC::Listener { |
75 public: | 75 public: |
76 ~RenderWidgetHostViewBase() override; | 76 ~RenderWidgetHostViewBase() override; |
77 | 77 |
| 78 float current_device_scale_factor() const { |
| 79 return current_device_scale_factor_; |
| 80 } |
| 81 |
78 // RenderWidgetHostView implementation. | 82 // RenderWidgetHostView implementation. |
79 void SetBackgroundColor(SkColor color) override; | 83 void SetBackgroundColor(SkColor color) override; |
80 void SetBackgroundColorToDefault() final; | 84 void SetBackgroundColorToDefault() final; |
81 bool GetBackgroundOpaque() override; | 85 bool GetBackgroundOpaque() override; |
82 ui::TextInputClient* GetTextInputClient() override; | 86 ui::TextInputClient* GetTextInputClient() override; |
83 void WasUnOccluded() override {} | 87 void WasUnOccluded() override {} |
84 void WasOccluded() override {} | 88 void WasOccluded() override {} |
85 bool IsShowingContextMenu() const override; | 89 bool IsShowingContextMenu() const override; |
86 void SetShowingContextMenu(bool showing_menu) override; | 90 void SetShowingContextMenu(bool showing_menu) override; |
87 base::string16 GetSelectedText() const override; | 91 base::string16 GetSelectedText() const override; |
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
451 base::OneShotTimer flush_input_timer_; | 455 base::OneShotTimer flush_input_timer_; |
452 | 456 |
453 base::WeakPtrFactory<RenderWidgetHostViewBase> weak_factory_; | 457 base::WeakPtrFactory<RenderWidgetHostViewBase> weak_factory_; |
454 | 458 |
455 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase); | 459 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewBase); |
456 }; | 460 }; |
457 | 461 |
458 } // namespace content | 462 } // namespace content |
459 | 463 |
460 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ | 464 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_BASE_H_ |
OLD | NEW |