refactor: remove references to non-existent webui (#20867)

This commit is contained in:
Jeremy Apthorp 2019-11-04 09:50:31 -08:00 committed by GitHub
parent f645ca015f
commit 85647dfced
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 395 additions and 174 deletions

View file

@ -59,6 +59,11 @@
#include "chrome/browser/picture_in_picture/picture_in_picture_window_manager.h"
#endif
#if BUILDFLAG(ENABLE_PDF_VIEWER)
#include "components/pdf/browser/pdf_web_contents_helper.h" // nogncheck
#include "shell/browser/electron_pdf_web_contents_helper_client.h"
#endif
using content::BrowserThread;
namespace electron {
@ -198,6 +203,11 @@ void CommonWebContentsDelegate::InitWithWebContents(
browser_context->GetUserAgent());
#endif
#if BUILDFLAG(ENABLE_PDF_VIEWER)
pdf::PDFWebContentsHelper::CreateForWebContentsWithClient(
web_contents, std::make_unique<ElectronPDFWebContentsHelperClient>());
#endif
// Determien whether the WebContents is offscreen.
auto* web_preferences = WebContentsPreferences::From(web_contents);
offscreen_ =