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 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); | 172 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); |
173 source_map->RegisterSource("declarativeContent", | 173 source_map->RegisterSource("declarativeContent", |
174 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); | 174 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); |
175 source_map->RegisterSource("desktopCapture", | 175 source_map->RegisterSource("desktopCapture", |
176 IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS); | 176 IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS); |
177 source_map->RegisterSource("developerPrivate", | 177 source_map->RegisterSource("developerPrivate", |
178 IDR_DEVELOPER_PRIVATE_CUSTOM_BINDINGS_JS); | 178 IDR_DEVELOPER_PRIVATE_CUSTOM_BINDINGS_JS); |
179 source_map->RegisterSource("downloads", IDR_DOWNLOADS_CUSTOM_BINDINGS_JS); | 179 source_map->RegisterSource("downloads", IDR_DOWNLOADS_CUSTOM_BINDINGS_JS); |
180 source_map->RegisterSource("feedbackPrivate", | 180 source_map->RegisterSource("feedbackPrivate", |
181 IDR_FEEDBACK_PRIVATE_CUSTOM_BINDINGS_JS); | 181 IDR_FEEDBACK_PRIVATE_CUSTOM_BINDINGS_JS); |
182 source_map->RegisterSource("fileSystem", IDR_FILE_SYSTEM_CUSTOM_BINDINGS_JS); | |
183 source_map->RegisterSource("gcm", IDR_GCM_CUSTOM_BINDINGS_JS); | 182 source_map->RegisterSource("gcm", IDR_GCM_CUSTOM_BINDINGS_JS); |
184 source_map->RegisterSource("identity", IDR_IDENTITY_CUSTOM_BINDINGS_JS); | 183 source_map->RegisterSource("identity", IDR_IDENTITY_CUSTOM_BINDINGS_JS); |
185 source_map->RegisterSource("imageWriterPrivate", | 184 source_map->RegisterSource("imageWriterPrivate", |
186 IDR_IMAGE_WRITER_PRIVATE_CUSTOM_BINDINGS_JS); | 185 IDR_IMAGE_WRITER_PRIVATE_CUSTOM_BINDINGS_JS); |
187 source_map->RegisterSource("input.ime", IDR_INPUT_IME_CUSTOM_BINDINGS_JS); | 186 source_map->RegisterSource("input.ime", IDR_INPUT_IME_CUSTOM_BINDINGS_JS); |
188 source_map->RegisterSource("logPrivate", IDR_LOG_PRIVATE_CUSTOM_BINDINGS_JS); | 187 source_map->RegisterSource("logPrivate", IDR_LOG_PRIVATE_CUSTOM_BINDINGS_JS); |
189 source_map->RegisterSource("mediaGalleries", | 188 source_map->RegisterSource("mediaGalleries", |
190 IDR_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS); | 189 IDR_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS); |
191 source_map->RegisterSource("notifications", | 190 source_map->RegisterSource("notifications", |
192 IDR_NOTIFICATIONS_CUSTOM_BINDINGS_JS); | 191 IDR_NOTIFICATIONS_CUSTOM_BINDINGS_JS); |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
311 } | 310 } |
312 | 311 |
313 void ChromeExtensionsDispatcherDelegate::InitializeBindingsSystem( | 312 void ChromeExtensionsDispatcherDelegate::InitializeBindingsSystem( |
314 extensions::Dispatcher* dispatcher, | 313 extensions::Dispatcher* dispatcher, |
315 extensions::APIBindingsSystem* bindings_system) { | 314 extensions::APIBindingsSystem* bindings_system) { |
316 DCHECK(extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()); | 315 DCHECK(extensions::FeatureSwitch::native_crx_bindings()->IsEnabled()); |
317 bindings_system->GetHooksForAPI("app")->SetDelegate( | 316 bindings_system->GetHooksForAPI("app")->SetDelegate( |
318 base::MakeUnique<extensions::AppHooksDelegate>( | 317 base::MakeUnique<extensions::AppHooksDelegate>( |
319 dispatcher, bindings_system->request_handler())); | 318 dispatcher, bindings_system->request_handler())); |
320 } | 319 } |
OLD | NEW |