mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
@@ -452,7 +452,9 @@ WebContents::WebContents(v8::Isolate* isolate,
|
||||
content::WebContents* web_contents)
|
||||
: content::WebContentsObserver(web_contents),
|
||||
type_(Type::REMOTE),
|
||||
#if BUILDFLAG(ENABLE_PRINTING)
|
||||
print_task_runner_(CreatePrinterHandlerTaskRunner()),
|
||||
#endif
|
||||
weak_factory_(this) {
|
||||
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
|
||||
// WebContents created by extension host will have valid ViewType set.
|
||||
@@ -487,7 +489,9 @@ WebContents::WebContents(v8::Isolate* isolate,
|
||||
Type type)
|
||||
: content::WebContentsObserver(web_contents.get()),
|
||||
type_(type),
|
||||
#if BUILDFLAG(ENABLE_PRINTING)
|
||||
print_task_runner_(CreatePrinterHandlerTaskRunner()),
|
||||
#endif
|
||||
weak_factory_(this) {
|
||||
DCHECK(type != Type::REMOTE)
|
||||
<< "Can't take ownership of a remote WebContents";
|
||||
@@ -499,7 +503,10 @@ WebContents::WebContents(v8::Isolate* isolate,
|
||||
|
||||
WebContents::WebContents(v8::Isolate* isolate,
|
||||
const gin_helper::Dictionary& options)
|
||||
: print_task_runner_(CreatePrinterHandlerTaskRunner()),
|
||||
:
|
||||
#if BUILDFLAG(ENABLE_PRINTING)
|
||||
print_task_runner_(CreatePrinterHandlerTaskRunner()),
|
||||
#endif
|
||||
weak_factory_(this) {
|
||||
// Read options.
|
||||
options.Get("backgroundThrottling", &background_throttling_);
|
||||
|
||||
@@ -656,7 +656,9 @@ class WebContents : public gin_helper::TrackableObject<WebContents>,
|
||||
// -1 means no speculative RVH has been committed yet.
|
||||
int currently_committed_process_id_ = -1;
|
||||
|
||||
#if BUILDFLAG(ENABLE_PRINTING)
|
||||
scoped_refptr<base::TaskRunner> print_task_runner_;
|
||||
#endif
|
||||
|
||||
service_manager::BinderRegistryWithArgs<content::RenderFrameHost*> registry_;
|
||||
mojo::ReceiverSet<mojom::ElectronBrowser, content::RenderFrameHost*>
|
||||
|
||||
Reference in New Issue
Block a user