| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #if defined(OS_MACOSX) | 9 #if defined(OS_MACOSX) |
| 10 #include <OpenGL/OpenGL.h> | 10 #include <OpenGL/OpenGL.h> |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 | 32 |
| 33 class BackingStore; | 33 class BackingStore; |
| 34 class RenderProcessHost; | 34 class RenderProcessHost; |
| 35 class RenderWidgetHost; | 35 class RenderWidgetHost; |
| 36 class WebCursor; | 36 class WebCursor; |
| 37 struct NativeWebKeyboardEvent; | 37 struct NativeWebKeyboardEvent; |
| 38 struct ViewHostMsg_AccessibilityNotification_Params; | 38 struct ViewHostMsg_AccessibilityNotification_Params; |
| 39 | 39 |
| 40 namespace webkit_glue { | 40 namespace webkit_glue { |
| 41 struct WebAccessibility; | 41 struct WebAccessibility; |
| 42 } |
| 43 |
| 44 namespace webkit { |
| 45 namespace npapi { |
| 42 struct WebPluginGeometry; | 46 struct WebPluginGeometry; |
| 43 } | 47 } |
| 48 } |
| 44 | 49 |
| 45 // RenderWidgetHostView is an interface implemented by an object that acts as | 50 // RenderWidgetHostView is an interface implemented by an object that acts as |
| 46 // the "View" portion of a RenderWidgetHost. The RenderWidgetHost and its | 51 // the "View" portion of a RenderWidgetHost. The RenderWidgetHost and its |
| 47 // associated RenderProcessHost own the "Model" in this case which is the | 52 // associated RenderProcessHost own the "Model" in this case which is the |
| 48 // child renderer process. The View is responsible for receiving events from | 53 // child renderer process. The View is responsible for receiving events from |
| 49 // the surrounding environment and passing them to the RenderWidgetHost, and | 54 // the surrounding environment and passing them to the RenderWidgetHost, and |
| 50 // for actually displaying the content of the RenderWidgetHost when it | 55 // for actually displaying the content of the RenderWidgetHost when it |
| 51 // changes. | 56 // changes. |
| 52 class RenderWidgetHostView { | 57 class RenderWidgetHostView { |
| 53 public: | 58 public: |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 | 95 |
| 91 // Tells the View to size itself to the specified size. | 96 // Tells the View to size itself to the specified size. |
| 92 virtual void SetSize(const gfx::Size& size) = 0; | 97 virtual void SetSize(const gfx::Size& size) = 0; |
| 93 | 98 |
| 94 // Retrieves the native view used to contain plugins and identify the | 99 // Retrieves the native view used to contain plugins and identify the |
| 95 // renderer in IPC messages. | 100 // renderer in IPC messages. |
| 96 virtual gfx::NativeView GetNativeView() = 0; | 101 virtual gfx::NativeView GetNativeView() = 0; |
| 97 | 102 |
| 98 // Moves all plugin windows as described in the given list. | 103 // Moves all plugin windows as described in the given list. |
| 99 virtual void MovePluginWindows( | 104 virtual void MovePluginWindows( |
| 100 const std::vector<webkit_glue::WebPluginGeometry>& moves) = 0; | 105 const std::vector<webkit::npapi::WebPluginGeometry>& moves) = 0; |
| 101 | 106 |
| 102 // Actually set/take focus to/from the associated View component. | 107 // Actually set/take focus to/from the associated View component. |
| 103 virtual void Focus() = 0; | 108 virtual void Focus() = 0; |
| 104 virtual void Blur() = 0; | 109 virtual void Blur() = 0; |
| 105 | 110 |
| 106 // Returns true if the View currently has the focus. | 111 // Returns true if the View currently has the focus. |
| 107 virtual bool HasFocus() = 0; | 112 virtual bool HasFocus() = 0; |
| 108 | 113 |
| 109 // Shows/hides the view. These must always be called together in pairs. | 114 // Shows/hides the view. These must always be called together in pairs. |
| 110 // It is not legal to call Hide() multiple times in a row. | 115 // It is not legal to call Hide() multiple times in a row. |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 | 309 |
| 305 // The current reserved area in view coordinates where contents should not be | 310 // The current reserved area in view coordinates where contents should not be |
| 306 // rendered to draw the resize corner, sidebar mini tabs etc. | 311 // rendered to draw the resize corner, sidebar mini tabs etc. |
| 307 gfx::Rect reserved_rect_; | 312 gfx::Rect reserved_rect_; |
| 308 | 313 |
| 309 private: | 314 private: |
| 310 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostView); | 315 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostView); |
| 311 }; | 316 }; |
| 312 | 317 |
| 313 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ | 318 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ |
| OLD | NEW |