build: fix build with enable_printing=false (#27456)
This commit is contained in:
		
					parent
					
						
							
								e7c201288c
							
						
					
				
			
			
				commit
				
					
						1023988ea8
					
				
			
		
					 2 changed files with 9 additions and 0 deletions
				
			
		|  | @ -618,7 +618,9 @@ WebContents::WebContents(v8::Isolate* isolate, | |||
|       devtools_file_system_indexer_(new DevToolsFileSystemIndexer), | ||||
|       file_task_runner_( | ||||
|           base::ThreadPool::CreateSequencedTaskRunner({base::MayBlock()})), | ||||
| #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.
 | ||||
|  | @ -652,7 +654,9 @@ WebContents::WebContents(v8::Isolate* isolate, | |||
|       devtools_file_system_indexer_(new DevToolsFileSystemIndexer), | ||||
|       file_task_runner_( | ||||
|           base::ThreadPool::CreateSequencedTaskRunner({base::MayBlock()})), | ||||
| #if BUILDFLAG(ENABLE_PRINTING) | ||||
|       print_task_runner_(CreatePrinterHandlerTaskRunner()), | ||||
| #endif | ||||
|       weak_factory_(this) { | ||||
|   DCHECK(type != Type::kRemote) | ||||
|       << "Can't take ownership of a remote WebContents"; | ||||
|  | @ -668,7 +672,9 @@ WebContents::WebContents(v8::Isolate* isolate, | |||
|       devtools_file_system_indexer_(new DevToolsFileSystemIndexer), | ||||
|       file_task_runner_( | ||||
|           base::ThreadPool::CreateSequencedTaskRunner({base::MayBlock()})), | ||||
| #if BUILDFLAG(ENABLE_PRINTING) | ||||
|       print_task_runner_(CreatePrinterHandlerTaskRunner()), | ||||
| #endif | ||||
|       weak_factory_(this) { | ||||
|   // Read options.
 | ||||
|   options.Get("backgroundThrottling", &background_throttling_); | ||||
|  |  | |||
|  | @ -777,7 +777,10 @@ class WebContents : public gin::Wrappable<WebContents>, | |||
|   DevToolsIndexingJobsMap devtools_indexing_jobs_; | ||||
| 
 | ||||
|   scoped_refptr<base::SequencedTaskRunner> file_task_runner_; | ||||
| 
 | ||||
| #if BUILDFLAG(ENABLE_PRINTING) | ||||
|   scoped_refptr<base::TaskRunner> print_task_runner_; | ||||
| #endif | ||||
| 
 | ||||
|   // Stores the frame thats currently in fullscreen, nullptr if there is none.
 | ||||
|   content::RenderFrameHost* fullscreen_frame_ = nullptr; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Milan Burda
				Milan Burda