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_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
106 | 106 |
107 ~WebContentsImpl() override; | 107 ~WebContentsImpl() override; |
108 | 108 |
109 static WebContentsImpl* CreateWithOpener( | 109 static WebContentsImpl* CreateWithOpener( |
110 const WebContents::CreateParams& params, | 110 const WebContents::CreateParams& params, |
111 FrameTreeNode* opener); | 111 FrameTreeNode* opener); |
112 | 112 |
113 static std::vector<WebContentsImpl*> GetAllWebContents(); | 113 static std::vector<WebContentsImpl*> GetAllWebContents(); |
114 | 114 |
115 static WebContentsImpl* FromFrameTreeNode(FrameTreeNode* frame_tree_node); | 115 static WebContentsImpl* FromFrameTreeNode(FrameTreeNode* frame_tree_node); |
| 116 static WebContents* FromRenderFrameHostID(int render_process_host_id, |
| 117 int render_frame_host_id); |
116 | 118 |
117 // Creates a swapped out RenderView. This is used by the browser plugin to | 119 // Creates a swapped out RenderView. This is used by the browser plugin to |
118 // create a swapped out RenderView in the embedder render process for the | 120 // create a swapped out RenderView in the embedder render process for the |
119 // guest, to expose the guest's window object to the embedder. | 121 // guest, to expose the guest's window object to the embedder. |
120 // This returns the routing ID of the newly created swapped out RenderView. | 122 // This returns the routing ID of the newly created swapped out RenderView. |
121 int CreateSwappedOutRenderView(SiteInstance* instance); | 123 int CreateSwappedOutRenderView(SiteInstance* instance); |
122 | 124 |
123 // Complex initialization here. Specifically needed to avoid having | 125 // Complex initialization here. Specifically needed to avoid having |
124 // members call back into our virtual functions in the constructor. | 126 // members call back into our virtual functions in the constructor. |
125 virtual void Init(const WebContents::CreateParams& params); | 127 virtual void Init(const WebContents::CreateParams& params); |
(...skipping 1224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1350 // Adds/removes a callback called on creation of each new WebContents. | 1352 // Adds/removes a callback called on creation of each new WebContents. |
1351 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); | 1353 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); |
1352 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); | 1354 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); |
1353 | 1355 |
1354 DISALLOW_COPY_AND_ASSIGN(FriendZone); | 1356 DISALLOW_COPY_AND_ASSIGN(FriendZone); |
1355 }; | 1357 }; |
1356 | 1358 |
1357 } // namespace content | 1359 } // namespace content |
1358 | 1360 |
1359 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1361 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
OLD | NEW |