OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.h" | 5 #include "chrome/renderer/extensions/chrome_extensions_dispatcher_delegate.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/sha1.h" | 10 #include "base/sha1.h" |
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 source_map->RegisterSource( | 268 source_map->RegisterSource( |
269 "chrome/common/media_router/mojo/media_status.mojom", | 269 "chrome/common/media_router/mojo/media_status.mojom", |
270 IDR_MEDIA_STATUS_MOJOM_JS); | 270 IDR_MEDIA_STATUS_MOJOM_JS); |
271 source_map->RegisterSource("media_router_bindings", | 271 source_map->RegisterSource("media_router_bindings", |
272 IDR_MEDIA_ROUTER_BINDINGS_JS); | 272 IDR_MEDIA_ROUTER_BINDINGS_JS); |
273 source_map->RegisterSource("mojo/common/time.mojom", IDR_MOJO_TIME_MOJOM_JS); | 273 source_map->RegisterSource("mojo/common/time.mojom", IDR_MOJO_TIME_MOJOM_JS); |
274 source_map->RegisterSource("net/interfaces/ip_address.mojom", | 274 source_map->RegisterSource("net/interfaces/ip_address.mojom", |
275 IDR_MOJO_IP_ADDRESS_MOJOM_JS); | 275 IDR_MOJO_IP_ADDRESS_MOJOM_JS); |
276 source_map->RegisterSource("url/mojo/origin.mojom", IDR_ORIGIN_MOJOM_JS); | 276 source_map->RegisterSource("url/mojo/origin.mojom", IDR_ORIGIN_MOJOM_JS); |
277 source_map->RegisterSource("url/mojo/url.mojom", IDR_MOJO_URL_MOJOM_JS); | 277 source_map->RegisterSource("url/mojo/url.mojom", IDR_MOJO_URL_MOJOM_JS); |
| 278 source_map->RegisterSource("media/mojo/interfaces/remoting_common.mojom", |
| 279 IDR_REMOTING_COMMON_JS); |
| 280 source_map->RegisterSource( |
| 281 "media/mojo/interfaces/mirror_service_remoting.mojom", |
| 282 IDR_MEDIA_REMOTING_JS); |
278 | 283 |
279 // These bindings are unnecessary with native bindings enabled. | 284 // These bindings are unnecessary with native bindings enabled. |
280 if (!extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()) { | 285 if (!extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()) { |
281 source_map->RegisterSource("app", IDR_APP_CUSTOM_BINDINGS_JS); | 286 source_map->RegisterSource("app", IDR_APP_CUSTOM_BINDINGS_JS); |
282 | 287 |
283 // Custom types sources. | 288 // Custom types sources. |
284 source_map->RegisterSource("ChromeSetting", IDR_CHROME_SETTING_JS); | 289 source_map->RegisterSource("ChromeSetting", IDR_CHROME_SETTING_JS); |
285 source_map->RegisterSource("ContentSetting", IDR_CONTENT_SETTING_JS); | 290 source_map->RegisterSource("ContentSetting", IDR_CONTENT_SETTING_JS); |
286 source_map->RegisterSource("ChromeDirectSetting", | 291 source_map->RegisterSource("ChromeDirectSetting", |
287 IDR_CHROME_DIRECT_SETTING_JS); | 292 IDR_CHROME_DIRECT_SETTING_JS); |
(...skipping 22 matching lines...) Expand all Loading... |
310 } | 315 } |
311 | 316 |
312 void ChromeExtensionsDispatcherDelegate::InitializeBindingsSystem( | 317 void ChromeExtensionsDispatcherDelegate::InitializeBindingsSystem( |
313 extensions::Dispatcher* dispatcher, | 318 extensions::Dispatcher* dispatcher, |
314 extensions::APIBindingsSystem* bindings_system) { | 319 extensions::APIBindingsSystem* bindings_system) { |
315 DCHECK(extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()); | 320 DCHECK(extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()); |
316 bindings_system->GetHooksForAPI("app")->SetDelegate( | 321 bindings_system->GetHooksForAPI("app")->SetDelegate( |
317 base::MakeUnique<extensions::AppHooksDelegate>( | 322 base::MakeUnique<extensions::AppHooksDelegate>( |
318 dispatcher, bindings_system->request_handler())); | 323 dispatcher, bindings_system->request_handler())); |
319 } | 324 } |
OLD | NEW |