Index: extensions/renderer/dispatcher.cc |
diff --git a/extensions/renderer/dispatcher.cc b/extensions/renderer/dispatcher.cc |
index 6522034fa41381c5a4565b6aa3e3c9455d79b313..f594b193cd1e7c84de0bf203d49e28f5a843bcae 100644 |
--- a/extensions/renderer/dispatcher.cc |
+++ b/extensions/renderer/dispatcher.cc |
@@ -574,9 +574,17 @@ std::vector<std::pair<std::string, int> > Dispatcher::GetJsResources() { |
std::make_pair(mojo::kUnicodeModuleName, IDR_MOJO_UNICODE_JS)); |
resources.push_back( |
std::make_pair(mojo::kValidatorModuleName, IDR_MOJO_VALIDATOR_JS)); |
+ resources.push_back(std::make_pair("async_waiter", IDR_ASYNC_WAITER_JS)); |
+ resources.push_back(std::make_pair("data_receiver", IDR_DATA_RECEIVER_JS)); |
+ resources.push_back(std::make_pair("data_sender", IDR_DATA_SENDER_JS)); |
resources.push_back(std::make_pair("keep_alive", IDR_KEEP_ALIVE_JS)); |
resources.push_back(std::make_pair("extensions/common/mojo/keep_alive.mojom", |
IDR_KEEP_ALIVE_MOJOM_JS)); |
+ resources.push_back(std::make_pair("device/serial/data_stream.mojom", |
+ IDR_DATA_STREAM_MOJOM_JS)); |
+ resources.push_back( |
+ std::make_pair("device/serial/data_stream_serialization.mojom", |
+ IDR_DATA_STREAM_SERIALIZATION_MOJOM_JS)); |
// Custom bindings. |
resources.push_back( |
@@ -601,6 +609,17 @@ std::vector<std::pair<std::string, int> > Dispatcher::GetJsResources() { |
IDR_WEB_VIEW_REQUEST_CUSTOM_BINDINGS_JS)); |
resources.push_back(std::make_pair("binding", IDR_BINDING_JS)); |
+ if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
+ switches::kEnableMojoSerialService)) { |
+ resources.push_back( |
+ std::make_pair("serial", IDR_SERIAL_CUSTOM_BINDINGS_JS)); |
+ } |
+ resources.push_back(std::make_pair("serial_service", IDR_SERIAL_SERVICE_JS)); |
+ resources.push_back( |
+ std::make_pair("device/serial/serial.mojom", IDR_SERIAL_MOJOM_JS)); |
+ resources.push_back(std::make_pair("device/serial/serial_serialization.mojom", |
+ IDR_SERIAL_SERIALIZATION_MOJOM_JS)); |
+ |
// Custom types sources. |
resources.push_back(std::make_pair("StorageArea", IDR_STORAGE_AREA_JS)); |