chore: bump chromium to cbeb16cf544f79c1990f1eae4d4fe (master) (#19610)

Co-authored-by: Erick Zhao <erickzhao@github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by Micha Hanselmann <DeerMichel@github.com>
This commit is contained in:
Electron Bot 2019-08-15 16:50:58 -04:00 committed by Shelley Vohr
parent 12df0e8994
commit db21391156
71 changed files with 348 additions and 355 deletions

View file

@ -20,13 +20,13 @@
#include "services/service_manager/sandbox/switches.h"
#if BUILDFLAG(ENABLE_PRINTING)
#include "chrome/services/printing/printing_service.h"
#include "chrome/services/printing/public/mojom/constants.mojom.h"
#include "components/services/pdf_compositor/public/cpp/pdf_compositor_service_factory.h"
#include "components/services/pdf_compositor/public/mojom/pdf_compositor.mojom.h"
#if defined(OS_WIN)
#include "chrome/services/printing/pdf_to_emf_converter_factory.h"
#include "chrome/services/printing/printing_service.h"
#include "chrome/services/printing/public/mojom/printing_service.mojom.h"
#include "chrome/utility/printing_handler.h"
#endif // defined(OS_WIN)
@ -43,6 +43,13 @@ void RunServiceAsyncThenTerminateProcess(
base::BindOnce([] { content::UtilityThread::Get()->ReleaseProcess(); }));
}
#if BUILDFLAG(ENABLE_PRINTING) && defined(OS_WIN)
auto RunPrintingService(
mojo::PendingReceiver<printing::mojom::PrintingService> receiver) {
return std::make_unique<printing::PrintingService>(std::move(receiver));
}
#endif
auto RunProxyResolver(
mojo::PendingReceiver<proxy_resolver::mojom::ProxyResolverFactory>
receiver) {
@ -119,6 +126,15 @@ bool AtomContentUtilityClient::HandleServiceRequest(
return false;
}
mojo::ServiceFactory* AtomContentUtilityClient::GetMainThreadServiceFactory() {
static base::NoDestructor<mojo::ServiceFactory> factory {
#if BUILDFLAG(ENABLE_PRINTING) && defined(OS_WIN)
RunPrintingService
#endif
};
return factory.get();
}
mojo::ServiceFactory* AtomContentUtilityClient::GetIOThreadServiceFactory() {
static base::NoDestructor<mojo::ServiceFactory> factory{RunProxyResolver};
return factory.get();
@ -132,10 +148,6 @@ AtomContentUtilityClient::MaybeCreateMainThreadService(
if (service_name == printing::mojom::kServiceName) {
return printing::CreatePdfCompositorService(std::move(request));
}
if (service_name == printing::mojom::kChromePrintingServiceName) {
return std::make_unique<printing::PrintingService>(std::move(request));
}
#endif
return nullptr;

View file

@ -29,6 +29,7 @@ class AtomContentUtilityClient : public content::ContentUtilityClient {
bool HandleServiceRequest(
const std::string& service_name,
service_manager::mojom::ServiceRequest request) override;
mojo::ServiceFactory* GetMainThreadServiceFactory() override;
mojo::ServiceFactory* GetIOThreadServiceFactory() override;
private: