| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/dispatcher.h" | 5 #include "chrome/renderer/extensions/dispatcher.h" |
| 6 | 6 |
| 7 #include "base/callback.h" | 7 #include "base/callback.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/debug/alias.h" | 9 #include "base/debug/alias.h" |
| 10 #include "base/json/json_reader.h" | 10 #include "base/json/json_reader.h" |
| (...skipping 966 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 977 source_map_.RegisterSource("sendRequest", IDR_SEND_REQUEST_JS); | 977 source_map_.RegisterSource("sendRequest", IDR_SEND_REQUEST_JS); |
| 978 source_map_.RegisterSource("setIcon", IDR_SET_ICON_JS); | 978 source_map_.RegisterSource("setIcon", IDR_SET_ICON_JS); |
| 979 source_map_.RegisterSource("test", IDR_TEST_CUSTOM_BINDINGS_JS); | 979 source_map_.RegisterSource("test", IDR_TEST_CUSTOM_BINDINGS_JS); |
| 980 source_map_.RegisterSource("unload_event", IDR_UNLOAD_EVENT_JS); | 980 source_map_.RegisterSource("unload_event", IDR_UNLOAD_EVENT_JS); |
| 981 source_map_.RegisterSource("utils", IDR_UTILS_JS); | 981 source_map_.RegisterSource("utils", IDR_UTILS_JS); |
| 982 | 982 |
| 983 // Custom bindings. | 983 // Custom bindings. |
| 984 source_map_.RegisterSource("app", IDR_APP_CUSTOM_BINDINGS_JS); | 984 source_map_.RegisterSource("app", IDR_APP_CUSTOM_BINDINGS_JS); |
| 985 source_map_.RegisterSource("app.runtime", IDR_APP_RUNTIME_CUSTOM_BINDINGS_JS); | 985 source_map_.RegisterSource("app.runtime", IDR_APP_RUNTIME_CUSTOM_BINDINGS_JS); |
| 986 source_map_.RegisterSource("app.window", IDR_APP_WINDOW_CUSTOM_BINDINGS_JS); | 986 source_map_.RegisterSource("app.window", IDR_APP_WINDOW_CUSTOM_BINDINGS_JS); |
| 987 source_map_.RegisterSource("bluetooth", IDR_BLUETOOTH_CUSTOM_BINDINGS_JS); | |
| 988 source_map_.RegisterSource("browserAction", | 987 source_map_.RegisterSource("browserAction", |
| 989 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); | 988 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); |
| 990 source_map_.RegisterSource("contextMenus", | 989 source_map_.RegisterSource("contextMenus", |
| 991 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS); | 990 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS); |
| 992 source_map_.RegisterSource("declarativeContent", | 991 source_map_.RegisterSource("declarativeContent", |
| 993 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); | 992 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); |
| 994 source_map_.RegisterSource("declarativeWebRequest", | 993 source_map_.RegisterSource("declarativeWebRequest", |
| 995 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS); | 994 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS); |
| 996 source_map_.RegisterSource("desktopCapture", | 995 source_map_.RegisterSource("desktopCapture", |
| 997 IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS); | 996 IDR_DESKTOP_CAPTURE_CUSTOM_BINDINGS_JS); |
| (...skipping 691 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1689 } | 1688 } |
| 1690 | 1689 |
| 1691 void Dispatcher::ClearPortData(int port_id) { | 1690 void Dispatcher::ClearPortData(int port_id) { |
| 1692 // Only the target port side has entries in |port_to_tab_id_map_|. If | 1691 // Only the target port side has entries in |port_to_tab_id_map_|. If |
| 1693 // |port_id| is a source port, std::map::erase() will just silently fail | 1692 // |port_id| is a source port, std::map::erase() will just silently fail |
| 1694 // here as a no-op. | 1693 // here as a no-op. |
| 1695 port_to_tab_id_map_.erase(port_id); | 1694 port_to_tab_id_map_.erase(port_id); |
| 1696 } | 1695 } |
| 1697 | 1696 |
| 1698 } // namespace extensions | 1697 } // namespace extensions |
| OLD | NEW |