Chromium Code Reviews| 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_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ | 5 #ifndef CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ |
| 6 #define CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ | 6 #define CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/process_util.h" | 9 #include "base/process_util.h" |
| 10 #include "base/string16.h" | 10 #include "base/string16.h" |
| 11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
| 12 #include "content/public/browser/render_widget_host_view.h" | 12 #include "content/public/browser/render_widget_host_view.h" |
| 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h" | 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h" |
| 14 #include "ui/base/ime/text_input_type.h" | 14 #include "ui/base/ime/text_input_type.h" |
| 15 #include "ui/base/range/range.h" | 15 #include "ui/base/range/range.h" |
| 16 #include "ui/surface/transport_dib.h" | 16 #include "ui/surface/transport_dib.h" |
| 17 | 17 |
| 18 class BackingStore; | |
| 19 class WebCursor; | 18 class WebCursor; |
| 20 | 19 |
| 21 struct AccessibilityHostMsg_NotificationParams; | 20 struct AccessibilityHostMsg_NotificationParams; |
| 22 struct GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params; | 21 struct GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params; |
| 23 struct GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params; | 22 struct GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params; |
| 24 | 23 |
| 25 namespace content { | 24 namespace content { |
| 25 class BackingStore; | |
|
jam
2012/07/20 23:35:39
nit: while you're here, can you move this down to
| |
| 26 struct NativeWebKeyboardEvent; | 26 struct NativeWebKeyboardEvent; |
| 27 } | 27 } |
| 28 | 28 |
| 29 namespace webkit { | 29 namespace webkit { |
| 30 namespace npapi { | 30 namespace npapi { |
| 31 struct WebPluginGeometry; | 31 struct WebPluginGeometry; |
| 32 } | 32 } |
| 33 } | 33 } |
| 34 | 34 |
| 35 #if defined(OS_POSIX) || defined(USE_AURA) | 35 #if defined(OS_POSIX) || defined(USE_AURA) |
| (...skipping 11 matching lines...) Expand all Loading... | |
| 47 // RenderWidgetHostView class hierarchy described in render_widget_host_view.h. | 47 // RenderWidgetHostView class hierarchy described in render_widget_host_view.h. |
| 48 class CONTENT_EXPORT RenderWidgetHostViewPort : public RenderWidgetHostView { | 48 class CONTENT_EXPORT RenderWidgetHostViewPort : public RenderWidgetHostView { |
| 49 public: | 49 public: |
| 50 virtual ~RenderWidgetHostViewPort() {} | 50 virtual ~RenderWidgetHostViewPort() {} |
| 51 | 51 |
| 52 // Does the cast for you. | 52 // Does the cast for you. |
| 53 static RenderWidgetHostViewPort* FromRWHV(RenderWidgetHostView* rwhv); | 53 static RenderWidgetHostViewPort* FromRWHV(RenderWidgetHostView* rwhv); |
| 54 | 54 |
| 55 // Like RenderWidgetHostView::CreateViewForWidget, with cast. | 55 // Like RenderWidgetHostView::CreateViewForWidget, with cast. |
| 56 static RenderWidgetHostViewPort* CreateViewForWidget( | 56 static RenderWidgetHostViewPort* CreateViewForWidget( |
| 57 content::RenderWidgetHost* widget); | 57 content::RenderWidgetHost* widget); |
|
jam
2012/07/20 23:35:39
and get rid of the "content::" in this file too
| |
| 58 | 58 |
| 59 // Perform all the initialization steps necessary for this object to represent | 59 // Perform all the initialization steps necessary for this object to represent |
| 60 // a popup (such as a <select> dropdown), then shows the popup at |pos|. | 60 // a popup (such as a <select> dropdown), then shows the popup at |pos|. |
| 61 virtual void InitAsPopup(RenderWidgetHostView* parent_host_view, | 61 virtual void InitAsPopup(RenderWidgetHostView* parent_host_view, |
| 62 const gfx::Rect& pos) = 0; | 62 const gfx::Rect& pos) = 0; |
| 63 | 63 |
| 64 // Perform all the initialization steps necessary for this object to represent | 64 // Perform all the initialization steps necessary for this object to represent |
| 65 // a full screen window. | 65 // a full screen window. |
| 66 // |reference_host_view| is the view associated with the creating page that | 66 // |reference_host_view| is the view associated with the creating page that |
| 67 // helps to position the full screen widget on the correct monitor. | 67 // helps to position the full screen widget on the correct monitor. |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 137 size_t offset, | 137 size_t offset, |
| 138 const ui::Range& range) = 0; | 138 const ui::Range& range) = 0; |
| 139 | 139 |
| 140 // Notifies the View that the renderer selection bounds has changed. | 140 // Notifies the View that the renderer selection bounds has changed. |
| 141 // |start_rect| and |end_rect| are the bounds end of the selection in the | 141 // |start_rect| and |end_rect| are the bounds end of the selection in the |
| 142 // coordinate system of the render view. | 142 // coordinate system of the render view. |
| 143 virtual void SelectionBoundsChanged(const gfx::Rect& start_rect, | 143 virtual void SelectionBoundsChanged(const gfx::Rect& start_rect, |
| 144 const gfx::Rect& end_rect) {} | 144 const gfx::Rect& end_rect) {} |
| 145 | 145 |
| 146 // Allocate a backing store for this view. | 146 // Allocate a backing store for this view. |
| 147 virtual BackingStore* AllocBackingStore(const gfx::Size& size) = 0; | 147 virtual content::BackingStore* AllocBackingStore(const gfx::Size& size) = 0; |
| 148 | 148 |
| 149 // Copies the contents of the compositing surface into the given | 149 // Copies the contents of the compositing surface into the given |
| 150 // (uninitialized) PlatformCanvas if any. | 150 // (uninitialized) PlatformCanvas if any. |
| 151 // |callback| is invoked with true on success, false otherwise. |output| can | 151 // |callback| is invoked with true on success, false otherwise. |output| can |
| 152 // be initialized even on failure. | 152 // be initialized even on failure. |
| 153 // NOTE: |callback| is called asynchronously on Aura and synchronously on the | 153 // NOTE: |callback| is called asynchronously on Aura and synchronously on the |
| 154 // other platforms. | 154 // other platforms. |
| 155 virtual void CopyFromCompositingSurface( | 155 virtual void CopyFromCompositingSurface( |
| 156 const gfx::Size& size, | 156 const gfx::Size& size, |
| 157 const base::Callback<void(bool)>& callback, | 157 const base::Callback<void(bool)>& callback, |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 267 virtual BrowserAccessibilityManager* | 267 virtual BrowserAccessibilityManager* |
| 268 GetBrowserAccessibilityManager() const = 0; | 268 GetBrowserAccessibilityManager() const = 0; |
| 269 virtual void OnAccessibilityNotifications( | 269 virtual void OnAccessibilityNotifications( |
| 270 const std::vector<AccessibilityHostMsg_NotificationParams>& params) { | 270 const std::vector<AccessibilityHostMsg_NotificationParams>& params) { |
| 271 } | 271 } |
| 272 }; | 272 }; |
| 273 | 273 |
| 274 } // namespace content | 274 } // namespace content |
| 275 | 275 |
| 276 #endif // CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ | 276 #endif // CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ |
| OLD | NEW |