Track child web contents
This commit is contained in:
parent
659722924d
commit
34ed1a9ef8
8 changed files with 55 additions and 55 deletions
|
@ -13,6 +13,7 @@
|
|||
#include "atom/browser/atom_browser_client.h"
|
||||
#include "atom/browser/atom_browser_context.h"
|
||||
#include "atom/browser/atom_browser_main_parts.h"
|
||||
#include "atom/browser/child_web_contents_tracker.h"
|
||||
#include "atom/browser/lib/bluetooth_chooser.h"
|
||||
#include "atom/browser/native_window.h"
|
||||
#include "atom/browser/net/atom_network_delegate.h"
|
||||
|
@ -466,6 +467,7 @@ void WebContents::AddNewContents(content::WebContents* source,
|
|||
const gfx::Rect& initial_rect,
|
||||
bool user_gesture,
|
||||
bool* was_blocked) {
|
||||
new ChildWebContentsTracker(new_contents);
|
||||
v8::Locker locker(isolate());
|
||||
v8::HandleScope handle_scope(isolate());
|
||||
auto api_web_contents = CreateFrom(isolate(), new_contents);
|
||||
|
|
|
@ -9,7 +9,6 @@
|
|||
#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"
|
||||
|
@ -101,7 +100,6 @@ 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);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue