diff --git chrome/browser/download/download_prefs.cc chrome/browser/download/download_prefs.cc index 1837e4c98e56..e6348c0e6dce 100644 --- chrome/browser/download/download_prefs.cc +++ chrome/browser/download/download_prefs.cc @@ -23,6 +23,7 @@ #include "base/strings/sys_string_conversions.h" #include "base/strings/utf_string_conversions.h" #include "build/build_config.h" +#include "cef/libcef/features/runtime.h" #include "chrome/browser/download/chrome_download_manager_delegate.h" #include "chrome/browser/download/download_core_service_factory.h" #include "chrome/browser/download/download_core_service_impl.h" @@ -57,6 +58,10 @@ #include "chrome/browser/ui/pdf/adobe_reader_info_win.h" #endif +#if BUILDFLAG(ENABLE_CEF) +#include "cef/libcef/browser/alloy/alloy_browser_context.h" +#endif + using content::BrowserContext; using content::BrowserThread; using content::DownloadManager; @@ -357,6 +362,11 @@ DownloadPrefs* DownloadPrefs::FromDownloadManager( // static DownloadPrefs* DownloadPrefs::FromBrowserContext( content::BrowserContext* context) { +#if BUILDFLAG(ENABLE_CEF) + if (cef::IsAlloyRuntimeEnabled()) { + return static_cast(context)->GetDownloadPrefs(); + } +#endif return FromDownloadManager(BrowserContext::GetDownloadManager(context)); } diff --git chrome/browser/printing/print_preview_dialog_controller.cc chrome/browser/printing/print_preview_dialog_controller.cc index 3fadaba3336f..5ef67b35883d 100644 --- chrome/browser/printing/print_preview_dialog_controller.cc +++ chrome/browser/printing/print_preview_dialog_controller.cc @@ -16,6 +16,7 @@ #include "base/strings/utf_string_conversions.h" #include "build/branding_buildflags.h" #include "build/build_config.h" +#include "cef/libcef/features/features.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/extensions/chrome_extension_web_contents_observer.h" #include "chrome/browser/printing/print_view_manager.h" @@ -451,8 +452,11 @@ WebContents* PrintPreviewDialogController::CreatePrintPreviewDialog( content::HostZoomMap::Get(preview_dialog->GetSiteInstance()) ->SetZoomLevelForHostAndScheme(print_url.scheme(), print_url.host(), 0); PrintViewManager::CreateForWebContents(preview_dialog); + +#if !BUILDFLAG(ENABLE_CEF) extensions::ChromeExtensionWebContentsObserver::CreateForWebContents( preview_dialog); +#endif // Add an entry to the map. preview_dialog_map_[preview_dialog] = initiator; diff --git chrome/browser/resources/print_preview/ui/destination_dialog.html chrome/browser/resources/print_preview/ui/destination_dialog.html index bc7f30dba388..2cc53441f17d 100644 --- chrome/browser/resources/print_preview/ui/destination_dialog.html +++ chrome/browser/resources/print_preview/ui/destination_dialog.html @@ -145,9 +145,7 @@
- - $i18n{manage} - +
$i18n{cancel} diff --git chrome/browser/resources/print_preview/ui/destination_select.html chrome/browser/resources/print_preview/ui/destination_select.html index 6d3d49c902e7..4769176b9550 100644 --- chrome/browser/resources/print_preview/ui/destination_select.html +++ chrome/browser/resources/print_preview/ui/destination_select.html @@ -20,10 +20,6 @@ -