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

Side by Side Diff: extensions/browser/app_window/app_window.cc

Issue 1685003002: Plumb the correct owner document through DocumentInit::m_owner. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Make initSecurityContext private. Created 4 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "extensions/browser/app_window/app_window.h" 5 #include "extensions/browser/app_window/app_window.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <string> 10 #include <string>
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 requested_alpha_enabled_(false), 252 requested_alpha_enabled_(false),
253 is_ime_window_(false), 253 is_ime_window_(false),
254 image_loader_ptr_factory_(this) { 254 image_loader_ptr_factory_(this) {
255 ExtensionsBrowserClient* client = ExtensionsBrowserClient::Get(); 255 ExtensionsBrowserClient* client = ExtensionsBrowserClient::Get();
256 CHECK(!client->IsGuestSession(context) || context->IsOffTheRecord()) 256 CHECK(!client->IsGuestSession(context) || context->IsOffTheRecord())
257 << "Only off the record window may be opened in the guest mode."; 257 << "Only off the record window may be opened in the guest mode.";
258 } 258 }
259 259
260 void AppWindow::Init(const GURL& url, 260 void AppWindow::Init(const GURL& url,
261 AppWindowContents* app_window_contents, 261 AppWindowContents* app_window_contents,
262 content::RenderFrameHost* creator_frame,
262 const CreateParams& params) { 263 const CreateParams& params) {
263 // Initialize the render interface and web contents 264 // Initialize the render interface and web contents
264 app_window_contents_.reset(app_window_contents); 265 app_window_contents_.reset(app_window_contents);
265 app_window_contents_->Initialize(browser_context(), url); 266 app_window_contents_->Initialize(browser_context(), creator_frame, url);
266 267
267 initial_url_ = url; 268 initial_url_ = url;
268 269
269 content::WebContentsObserver::Observe(web_contents()); 270 content::WebContentsObserver::Observe(web_contents());
270 SetViewType(web_contents(), VIEW_TYPE_APP_WINDOW); 271 SetViewType(web_contents(), VIEW_TYPE_APP_WINDOW);
271 app_delegate_->InitWebContents(web_contents()); 272 app_delegate_->InitWebContents(web_contents());
272 273
273 ExtensionWebContentsObserver::GetForWebContents(web_contents())-> 274 ExtensionWebContentsObserver::GetForWebContents(web_contents())->
274 dispatcher()->set_delegate(this); 275 dispatcher()->set_delegate(this);
275 276
(...skipping 838 matching lines...) Expand 10 before | Expand all | Expand 10 after
1114 region.bounds.x(), 1115 region.bounds.x(),
1115 region.bounds.y(), 1116 region.bounds.y(),
1116 region.bounds.right(), 1117 region.bounds.right(),
1117 region.bounds.bottom(), 1118 region.bounds.bottom(),
1118 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op); 1119 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op);
1119 } 1120 }
1120 return sk_region; 1121 return sk_region;
1121 } 1122 }
1122 1123
1123 } // namespace extensions 1124 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698