Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Unified Diff: third_party/WebKit/Source/web/WebViewImpl.cpp

Issue 2873503002: NOT YET READY: Improve granularity of window namespaces in Blink.
Patch Set: Rebasing... Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/web/WebViewImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebViewImpl.cpp b/third_party/WebKit/Source/web/WebViewImpl.cpp
index 3d69245549d92863a3d115277446ca7d00dafaa7..91dd171107f98c8d3530853a917604bc246260c8 100644
--- a/third_party/WebKit/Source/web/WebViewImpl.cpp
+++ b/third_party/WebKit/Source/web/WebViewImpl.cpp
@@ -269,14 +269,17 @@ class ColorOverlay final : public PageOverlay::Delegate {
// WebView ----------------------------------------------------------------
WebView* WebView::Create(WebViewClient* client,
- WebPageVisibilityState visibility_state) {
- return WebViewImpl::Create(client, visibility_state);
+ WebPageVisibilityState visibility_state,
+ WebView* opener) {
+ return WebViewImpl::Create(client, visibility_state,
+ static_cast<WebViewImpl*>(opener));
}
WebViewBase* WebViewImpl::Create(WebViewClient* client,
- WebPageVisibilityState visibility_state) {
+ WebPageVisibilityState visibility_state,
+ WebViewImpl* opener) {
// Pass the WebViewImpl's self-reference to the caller.
- return AdoptRef(new WebViewImpl(client, visibility_state)).LeakRef();
+ return AdoptRef(new WebViewImpl(client, visibility_state, opener)).LeakRef();
}
const WebInputEvent* WebViewBase::CurrentInputEvent() {
@@ -333,7 +336,8 @@ HashSet<WebViewBase*>& WebViewBase::AllInstances() {
}
WebViewImpl::WebViewImpl(WebViewClient* client,
- WebPageVisibilityState visibility_state)
+ WebPageVisibilityState visibility_state,
+ WebViewImpl* opener)
: client_(client),
spell_check_client_(nullptr),
chrome_client_(WebFactory::GetInstance().CreateChromeClient(this)),
@@ -390,7 +394,8 @@ WebViewImpl::WebViewImpl(WebViewClient* client,
page_clients.editor_client = &editor_client_impl_;
page_clients.spell_checker_client = &spell_checker_client_impl_;
- page_ = Page::CreateOrdinary(page_clients);
+ page_ =
+ Page::CreateOrdinary(page_clients, opener ? opener->GetPage() : nullptr);
MediaKeysController::ProvideMediaKeysTo(*page_, &media_keys_client_impl_);
ProvideSpeechRecognitionTo(
*page_, SpeechRecognitionClientProxy::Create(
« no previous file with comments | « third_party/WebKit/Source/web/WebViewImpl.h ('k') | third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698