2014-09-04 19:53:40 +02:00
|
|
|
diff --git web_contents.cc web_contents.cc
|
2015-11-10 21:18:16 +01:00
|
|
|
index 1b6d8a6..b606a30 100644
|
2014-09-04 19:53:40 +02:00
|
|
|
--- web_contents.cc
|
|
|
|
+++ web_contents.cc
|
2015-11-10 21:18:16 +01:00
|
|
|
@@ -26,7 +26,9 @@ WebContents::CreateParams::CreateParams(BrowserContext* context,
|
2014-07-01 00:30:29 +02:00
|
|
|
initially_hidden(false),
|
2015-02-04 19:10:14 +01:00
|
|
|
guest_delegate(nullptr),
|
2015-03-04 02:00:13 +01:00
|
|
|
context(nullptr),
|
|
|
|
- renderer_initiated_creation(false) {}
|
|
|
|
+ renderer_initiated_creation(false),
|
2015-02-04 19:10:14 +01:00
|
|
|
+ view(nullptr),
|
|
|
|
+ delegate_view(nullptr) {}
|
2014-07-01 00:30:29 +02:00
|
|
|
|
|
|
|
WebContents::CreateParams::~CreateParams() {
|
|
|
|
}
|
2014-09-04 19:53:40 +02:00
|
|
|
diff --git web_contents.h web_contents.h
|
2015-12-09 17:10:16 +01:00
|
|
|
index c9fa8a01..e075a76 100644
|
2014-09-04 19:53:40 +02:00
|
|
|
--- web_contents.h
|
|
|
|
+++ web_contents.h
|
|
|
|
@@ -52,9 +52,11 @@ class PageState;
|
2014-07-01 00:30:29 +02:00
|
|
|
class RenderFrameHost;
|
|
|
|
class RenderProcessHost;
|
|
|
|
class RenderViewHost;
|
|
|
|
+class RenderViewHostDelegateView;
|
|
|
|
class RenderWidgetHostView;
|
|
|
|
class SiteInstance;
|
|
|
|
class WebContentsDelegate;
|
|
|
|
+class WebContentsView;
|
|
|
|
struct CustomContextMenuContext;
|
|
|
|
struct DropData;
|
2014-09-27 01:48:19 +02:00
|
|
|
struct Manifest;
|
2015-11-10 21:18:16 +01:00
|
|
|
@@ -144,6 +146,10 @@ class WebContents : public PageNavigator,
|
2015-03-04 02:00:13 +01:00
|
|
|
// RenderFrame, have already been created on the renderer side, and
|
|
|
|
// WebContents construction should take this into account.
|
|
|
|
bool renderer_initiated_creation;
|
|
|
|
+
|
2014-07-01 00:30:29 +02:00
|
|
|
+ // Optionally specify the view and delegate view.
|
|
|
|
+ content::WebContentsView* view;
|
|
|
|
+ content::RenderViewHostDelegateView* delegate_view;
|
|
|
|
};
|
|
|
|
|
|
|
|
// Creates a new WebContents.
|
2014-09-04 19:53:40 +02:00
|
|
|
diff --git web_contents_delegate.cc web_contents_delegate.cc
|
2015-12-09 17:10:16 +01:00
|
|
|
index 70a1f06..b9673d2 100644
|
2014-09-04 19:53:40 +02:00
|
|
|
--- web_contents_delegate.cc
|
|
|
|
+++ web_contents_delegate.cc
|
2015-12-09 17:10:16 +01:00
|
|
|
@@ -165,7 +165,9 @@ bool WebContentsDelegate::ShouldCreateWebContents(
|
2015-07-24 02:06:56 +02:00
|
|
|
const std::string& frame_name,
|
2014-07-01 00:30:29 +02:00
|
|
|
const GURL& target_url,
|
|
|
|
const std::string& partition_id,
|
|
|
|
- SessionStorageNamespace* session_storage_namespace) {
|
|
|
|
+ SessionStorageNamespace* session_storage_namespace,
|
|
|
|
+ content::WebContentsView** view,
|
|
|
|
+ content::RenderViewHostDelegateView** delegate_view) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2014-09-04 19:53:40 +02:00
|
|
|
diff --git web_contents_delegate.h web_contents_delegate.h
|
2015-12-09 17:10:16 +01:00
|
|
|
index f6a04a5..f41ec5b 100644
|
2014-09-04 19:53:40 +02:00
|
|
|
--- web_contents_delegate.h
|
|
|
|
+++ web_contents_delegate.h
|
2015-10-09 17:23:12 +02:00
|
|
|
@@ -39,9 +39,11 @@ class DownloadItem;
|
2014-07-01 00:30:29 +02:00
|
|
|
class JavaScriptDialogManager;
|
|
|
|
class PageState;
|
|
|
|
class RenderViewHost;
|
|
|
|
+class RenderViewHostDelegateView;
|
|
|
|
class SessionStorageNamespace;
|
|
|
|
class WebContents;
|
|
|
|
class WebContentsImpl;
|
|
|
|
+class WebContentsView;
|
|
|
|
struct ColorSuggestion;
|
|
|
|
struct ContextMenuParams;
|
|
|
|
struct DropData;
|
2015-11-10 21:18:16 +01:00
|
|
|
@@ -296,7 +298,9 @@ class CONTENT_EXPORT WebContentsDelegate {
|
2015-07-24 02:06:56 +02:00
|
|
|
const std::string& frame_name,
|
2014-07-01 00:30:29 +02:00
|
|
|
const GURL& target_url,
|
|
|
|
const std::string& partition_id,
|
|
|
|
- SessionStorageNamespace* session_storage_namespace);
|
|
|
|
+ SessionStorageNamespace* session_storage_namespace,
|
|
|
|
+ content::WebContentsView** view,
|
|
|
|
+ content::RenderViewHostDelegateView** delegate_view);
|
|
|
|
|
|
|
|
// Notifies the delegate about the creation of a new WebContents. This
|
|
|
|
// typically happens when popups are created.
|