Make sure BrowserContext is always destroyed after WebContents

This commit is contained in:
Cheng Zhao 2016-05-17 21:49:05 +09:00
parent 242508e22f
commit 118afab67b
3 changed files with 11 additions and 4 deletions

View file

@ -182,7 +182,9 @@ CommonWebContentsDelegate::~CommonWebContentsDelegate() {
}
void CommonWebContentsDelegate::InitWithWebContents(
content::WebContents* web_contents) {
content::WebContents* web_contents,
AtomBrowserContext* browser_context) {
browser_context_ = browser_context;
web_contents->SetDelegate(this);
printing::PrintViewManagerBasic::CreateForWebContents(web_contents);