| 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 "extensions/renderer/dispatcher.h" | 5 #include "extensions/renderer/dispatcher.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/alias.h" | 10 #include "base/debug/alias.h" |
| (...skipping 591 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 602 std::make_pair("app.window", IDR_APP_WINDOW_CUSTOM_BINDINGS_JS)); | 602 std::make_pair("app.window", IDR_APP_WINDOW_CUSTOM_BINDINGS_JS)); |
| 603 resources.push_back( | 603 resources.push_back( |
| 604 std::make_pair("declarativeWebRequest", | 604 std::make_pair("declarativeWebRequest", |
| 605 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS)); | 605 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS)); |
| 606 resources.push_back( | 606 resources.push_back( |
| 607 std::make_pair("contextMenus", IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS)); | 607 std::make_pair("contextMenus", IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS)); |
| 608 resources.push_back( | 608 resources.push_back( |
| 609 std::make_pair("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS)); | 609 std::make_pair("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS)); |
| 610 resources.push_back(std::make_pair("i18n", IDR_I18N_CUSTOM_BINDINGS_JS)); | 610 resources.push_back(std::make_pair("i18n", IDR_I18N_CUSTOM_BINDINGS_JS)); |
| 611 resources.push_back( | 611 resources.push_back( |
| 612 std::make_pair("mimeHandler", IDR_MIME_HANDLER_CUSTOM_BINDINGS_JS)); |
| 613 resources.push_back(std::make_pair("extensions/common/api/mime_handler.mojom", |
| 614 IDR_MIME_HANDLER_MOJOM_JS)); |
| 615 resources.push_back( |
| 612 std::make_pair("permissions", IDR_PERMISSIONS_CUSTOM_BINDINGS_JS)); | 616 std::make_pair("permissions", IDR_PERMISSIONS_CUSTOM_BINDINGS_JS)); |
| 613 resources.push_back( | 617 resources.push_back( |
| 614 std::make_pair("runtime", IDR_RUNTIME_CUSTOM_BINDINGS_JS)); | 618 std::make_pair("runtime", IDR_RUNTIME_CUSTOM_BINDINGS_JS)); |
| 615 resources.push_back(std::make_pair("windowControls", IDR_WINDOW_CONTROLS_JS)); | 619 resources.push_back(std::make_pair("windowControls", IDR_WINDOW_CONTROLS_JS)); |
| 616 resources.push_back( | 620 resources.push_back( |
| 617 std::make_pair("webViewRequest", | 621 std::make_pair("webViewRequest", |
| 618 IDR_WEB_VIEW_REQUEST_CUSTOM_BINDINGS_JS)); | 622 IDR_WEB_VIEW_REQUEST_CUSTOM_BINDINGS_JS)); |
| 619 resources.push_back(std::make_pair("binding", IDR_BINDING_JS)); | 623 resources.push_back(std::make_pair("binding", IDR_BINDING_JS)); |
| 620 | 624 |
| 621 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 625 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| (...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1417 return v8::Handle<v8::Object>(); | 1421 return v8::Handle<v8::Object>(); |
| 1418 | 1422 |
| 1419 if (bind_name) | 1423 if (bind_name) |
| 1420 *bind_name = split.back(); | 1424 *bind_name = split.back(); |
| 1421 | 1425 |
| 1422 return bind_object.IsEmpty() ? AsObjectOrEmpty(GetOrCreateChrome(context)) | 1426 return bind_object.IsEmpty() ? AsObjectOrEmpty(GetOrCreateChrome(context)) |
| 1423 : bind_object; | 1427 : bind_object; |
| 1424 } | 1428 } |
| 1425 | 1429 |
| 1426 } // namespace extensions | 1430 } // namespace extensions |
| OLD | NEW |