Improve RootWebContentsTracker

This commit is contained in:
Ryohei Ikegami 2017-04-06 11:29:01 +09:00
parent b683584859
commit 526086d900
6 changed files with 55 additions and 28 deletions

View file

@ -9,6 +9,7 @@
#include "atom/browser/api/atom_api_web_contents.h"
#include "atom/browser/browser.h"
#include "atom/browser/native_window.h"
#include "atom/browser/root_web_contents_tracker.h"
#include "atom/common/native_mate_converters/callback.h"
#include "atom/common/native_mate_converters/file_path_converter.h"
#include "atom/common/native_mate_converters/gfx_converter.h"
@ -100,6 +101,7 @@ Window::Window(v8::Isolate* isolate, v8::Local<v8::Object> wrapper,
// Creates the WebContents used by BrowserWindow.
web_contents = WebContents::Create(isolate, web_preferences);
new RootWebContentsTracker(web_contents.get()->web_contents());
}
Init(isolate, wrapper, options, web_contents);