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 #ifndef EXTENSIONS_RENDERER_DISPATCHER_H_ | 5 #ifndef EXTENSIONS_RENDERER_DISPATCHER_H_ |
6 #define EXTENSIONS_RENDERER_DISPATCHER_H_ | 6 #define EXTENSIONS_RENDERER_DISPATCHER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
11 #include <memory> | 11 #include <memory> |
12 #include <set> | 12 #include <set> |
13 #include <string> | 13 #include <string> |
14 #include <utility> | 14 #include <utility> |
15 #include <vector> | 15 #include <vector> |
16 | 16 |
17 #include "base/gtest_prod_util.h" | 17 #include "base/gtest_prod_util.h" |
18 #include "base/macros.h" | 18 #include "base/macros.h" |
19 #include "base/scoped_observer.h" | 19 #include "base/scoped_observer.h" |
20 #include "base/timer/timer.h" | 20 #include "base/timer/timer.h" |
| 21 #include "components/version_info/version_info.h" |
21 #include "content/public/renderer/render_thread_observer.h" | 22 #include "content/public/renderer/render_thread_observer.h" |
22 #include "extensions/common/event_filter.h" | 23 #include "extensions/common/event_filter.h" |
23 #include "extensions/common/extension.h" | 24 #include "extensions/common/extension.h" |
24 #include "extensions/common/extensions_client.h" | 25 #include "extensions/common/extensions_client.h" |
25 #include "extensions/common/features/feature.h" | 26 #include "extensions/common/features/feature.h" |
26 #include "extensions/renderer/resource_bundle_source_map.h" | 27 #include "extensions/renderer/resource_bundle_source_map.h" |
27 #include "extensions/renderer/script_context.h" | 28 #include "extensions/renderer/script_context.h" |
28 #include "extensions/renderer/script_context_set.h" | 29 #include "extensions/renderer/script_context_set.h" |
29 #include "extensions/renderer/user_script_set_manager.h" | 30 #include "extensions/renderer/user_script_set_manager.h" |
30 #include "extensions/renderer/v8_schema_registry.h" | 31 #include "extensions/renderer/v8_schema_registry.h" |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 const ExtensionMsg_ExternalConnectionInfo& info, | 173 const ExtensionMsg_ExternalConnectionInfo& info, |
173 const std::string& tls_channel_id); | 174 const std::string& tls_channel_id); |
174 void OnDispatchOnDisconnect(int port_id, const std::string& error_message); | 175 void OnDispatchOnDisconnect(int port_id, const std::string& error_message); |
175 void OnLoaded( | 176 void OnLoaded( |
176 const std::vector<ExtensionMsg_Loaded_Params>& loaded_extensions); | 177 const std::vector<ExtensionMsg_Loaded_Params>& loaded_extensions); |
177 void OnMessageInvoke(const std::string& extension_id, | 178 void OnMessageInvoke(const std::string& extension_id, |
178 const std::string& module_name, | 179 const std::string& module_name, |
179 const std::string& function_name, | 180 const std::string& function_name, |
180 const base::ListValue& args, | 181 const base::ListValue& args, |
181 bool user_gesture); | 182 bool user_gesture); |
182 void OnSetChannel(int channel); | 183 void OnSetChannel(version_info::Channel channel); |
183 void OnSetScriptingWhitelist( | 184 void OnSetScriptingWhitelist( |
184 const ExtensionsClient::ScriptingWhitelist& extension_ids); | 185 const ExtensionsClient::ScriptingWhitelist& extension_ids); |
185 void OnSetSystemFont(const std::string& font_family, | 186 void OnSetSystemFont(const std::string& font_family, |
186 const std::string& font_size); | 187 const std::string& font_size); |
187 void OnSetWebViewPartitionID(const std::string& partition_id); | 188 void OnSetWebViewPartitionID(const std::string& partition_id); |
188 void OnShouldSuspend(const std::string& extension_id, uint64_t sequence_id); | 189 void OnShouldSuspend(const std::string& extension_id, uint64_t sequence_id); |
189 void OnSuspend(const std::string& extension_id); | 190 void OnSuspend(const std::string& extension_id); |
190 void OnTransferBlobs(const std::vector<std::string>& blob_uuids); | 191 void OnTransferBlobs(const std::vector<std::string>& blob_uuids); |
191 void OnUnloaded(const std::string& id); | 192 void OnUnloaded(const std::string& id); |
192 void OnUpdatePermissions(const ExtensionMsg_UpdatePermissions_Params& params); | 193 void OnUpdatePermissions(const ExtensionMsg_UpdatePermissions_Params& params); |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
318 // if this renderer is a WebView guest render process. Otherwise, this will be | 319 // if this renderer is a WebView guest render process. Otherwise, this will be |
319 // empty. | 320 // empty. |
320 std::string webview_partition_id_; | 321 std::string webview_partition_id_; |
321 | 322 |
322 DISALLOW_COPY_AND_ASSIGN(Dispatcher); | 323 DISALLOW_COPY_AND_ASSIGN(Dispatcher); |
323 }; | 324 }; |
324 | 325 |
325 } // namespace extensions | 326 } // namespace extensions |
326 | 327 |
327 #endif // EXTENSIONS_RENDERER_DISPATCHER_H_ | 328 #endif // EXTENSIONS_RENDERER_DISPATCHER_H_ |
OLD | NEW |