Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(813)

Unified Diff: mandoline/services/core_services/core_services_application_delegate.cc

Issue 1135703004: core_services: add native_viewport_service on non-android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mandoline/services/core_services/DEPS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mandoline/services/core_services/core_services_application_delegate.cc
diff --git a/mandoline/services/core_services/core_services_application_delegate.cc b/mandoline/services/core_services/core_services_application_delegate.cc
index 5104cacc6904c675671f3a8126ac87ff31e57872..5eeb52c8fc24a9364af91f52ba3ed094ee5ac21f 100644
--- a/mandoline/services/core_services/core_services_application_delegate.cc
+++ b/mandoline/services/core_services/core_services_application_delegate.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "components/clipboard/clipboard_application_delegate.h"
+#include "components/native_viewport/native_viewport_application_delegate.h"
#include "components/resource_provider/resource_provider_app.h"
#include "components/surfaces/surfaces_service_application.h"
#include "components/view_manager/view_manager_app.h"
@@ -128,6 +129,10 @@ void CoreServicesApplicationDelegate::StartApplication(
scoped_ptr<mojo::ApplicationDelegate> delegate;
if (url == "mojo://clipboard/")
delegate.reset(new clipboard::ClipboardApplicationDelegate);
+#if !defined(OS_ANDROID)
+ else if (url == "mojo://native_viewport_service/")
+ delegate.reset(new native_viewport::NativeViewportApplicationDelegate);
+#endif
else if (url == "mojo://network_service/")
delegate.reset(new NetworkServiceDelegate);
#if !defined(OS_ANDROID)
@@ -152,6 +157,8 @@ void CoreServicesApplicationDelegate::StartApplication(
// In the case of mojo:network_service, we must use an IO message loop.
if (url == "mojo://network_service/") {
thread_options.message_loop_type = base::MessageLoop::TYPE_IO;
+ } else if (url == "mojo://native_viewport_service/") {
+ thread_options.message_loop_type = base::MessageLoop::TYPE_UI;
} else {
// We must use a MessagePumpMojo to awake on mojo messages.
thread_options.message_pump_factory =
« no previous file with comments | « mandoline/services/core_services/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698