| 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_VIEW_HOST_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 RenderViewHost(SiteInstance* instance, | 96 RenderViewHost(SiteInstance* instance, |
| 97 RenderViewHostDelegate* delegate, | 97 RenderViewHostDelegate* delegate, |
| 98 int routing_id, | 98 int routing_id, |
| 99 int64 session_storage_namespace_id); | 99 int64 session_storage_namespace_id); |
| 100 virtual ~RenderViewHost(); | 100 virtual ~RenderViewHost(); |
| 101 | 101 |
| 102 SiteInstance* site_instance() const { return instance_; } | 102 SiteInstance* site_instance() const { return instance_; } |
| 103 RenderViewHostDelegate* delegate() const { return delegate_; } | 103 RenderViewHostDelegate* delegate() const { return delegate_; } |
| 104 | 104 |
| 105 // Set up the RenderView child process. Virtual because it is overridden by | 105 // Set up the RenderView child process. Virtual because it is overridden by |
| 106 // TestRenderViewHost. | 106 // TestRenderViewHost. If the |frame_name| parameter is non-empty, it is used |
| 107 virtual bool CreateRenderView(URLRequestContextGetter* request_context); | 107 // as the name of the new top-level frame. |
| 108 virtual bool CreateRenderView(URLRequestContextGetter* request_context, |
| 109 const string16& frame_name); |
| 108 | 110 |
| 109 // Returns true if the RenderView is active and has not crashed. Virtual | 111 // Returns true if the RenderView is active and has not crashed. Virtual |
| 110 // because it is overridden by TestRenderViewHost. | 112 // because it is overridden by TestRenderViewHost. |
| 111 virtual bool IsRenderViewLive() const; | 113 virtual bool IsRenderViewLive() const; |
| 112 | 114 |
| 113 // Send the renderer process the current preferences supplied by the | 115 // Send the renderer process the current preferences supplied by the |
| 114 // RenderViewHostDelegate. | 116 // RenderViewHostDelegate. |
| 115 void SyncRendererPrefs(); | 117 void SyncRendererPrefs(); |
| 116 | 118 |
| 117 // Sends the given navigation message. Use this rather than sending it | 119 // Sends the given navigation message. Use this rather than sending it |
| (...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 410 virtual void ForwardMouseEvent(const WebKit::WebMouseEvent& mouse_event); | 412 virtual void ForwardMouseEvent(const WebKit::WebMouseEvent& mouse_event); |
| 411 virtual void ForwardKeyboardEvent(const NativeWebKeyboardEvent& key_event); | 413 virtual void ForwardKeyboardEvent(const NativeWebKeyboardEvent& key_event); |
| 412 virtual void ForwardEditCommand(const std::string& name, | 414 virtual void ForwardEditCommand(const std::string& name, |
| 413 const std::string& value); | 415 const std::string& value); |
| 414 virtual void ForwardEditCommandsForNextKeyEvent( | 416 virtual void ForwardEditCommandsForNextKeyEvent( |
| 415 const EditCommands& edit_commands); | 417 const EditCommands& edit_commands); |
| 416 virtual gfx::Rect GetRootWindowResizerRect() const; | 418 virtual gfx::Rect GetRootWindowResizerRect() const; |
| 417 | 419 |
| 418 // Creates a new RenderView with the given route id. | 420 // Creates a new RenderView with the given route id. |
| 419 void CreateNewWindow(int route_id, | 421 void CreateNewWindow(int route_id, |
| 420 WindowContainerType window_container_type); | 422 WindowContainerType window_container_type, |
| 423 const string16& frame_name); |
| 421 | 424 |
| 422 // Creates a new RenderWidget with the given route id. |popup_type| indicates | 425 // Creates a new RenderWidget with the given route id. |popup_type| indicates |
| 423 // if this widget is a popup and what kind of popup it is (select, autofill). | 426 // if this widget is a popup and what kind of popup it is (select, autofill). |
| 424 void CreateNewWidget(int route_id, WebKit::WebPopupType popup_type); | 427 void CreateNewWidget(int route_id, WebKit::WebPopupType popup_type); |
| 425 | 428 |
| 426 // Sends the response to an extension api call. | 429 // Sends the response to an extension api call. |
| 427 void SendExtensionResponse(int request_id, bool success, | 430 void SendExtensionResponse(int request_id, bool success, |
| 428 const std::string& response, | 431 const std::string& response, |
| 429 const std::string& error); | 432 const std::string& error); |
| 430 | 433 |
| (...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 706 int64 session_storage_namespace_id_; | 709 int64 session_storage_namespace_id_; |
| 707 | 710 |
| 708 // Whether this render view will be used for extensions. This controls | 711 // Whether this render view will be used for extensions. This controls |
| 709 // what process type we use. | 712 // what process type we use. |
| 710 bool is_extension_process_; | 713 bool is_extension_process_; |
| 711 | 714 |
| 712 DISALLOW_COPY_AND_ASSIGN(RenderViewHost); | 715 DISALLOW_COPY_AND_ASSIGN(RenderViewHost); |
| 713 }; | 716 }; |
| 714 | 717 |
| 715 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ | 718 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| OLD | NEW |