| 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 <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 const URLPatternSet& new_hosts, | 193 const URLPatternSet& new_hosts, |
| 194 bool update_origin_whitelist, | 194 bool update_origin_whitelist, |
| 195 int tab_id); | 195 int tab_id); |
| 196 void OnClearTabSpecificPermissions( | 196 void OnClearTabSpecificPermissions( |
| 197 const std::vector<std::string>& extension_ids, | 197 const std::vector<std::string>& extension_ids, |
| 198 bool update_origin_whitelist, | 198 bool update_origin_whitelist, |
| 199 int tab_id); | 199 int tab_id); |
| 200 void OnUsingWebRequestAPI(bool webrequest_used); | 200 void OnUsingWebRequestAPI(bool webrequest_used); |
| 201 | 201 |
| 202 // UserScriptSetManager::Observer implementation. | 202 // UserScriptSetManager::Observer implementation. |
| 203 void OnUserScriptsUpdated(const std::set<std::string>& changed_extensions, | 203 void OnUserScriptsUpdated(const std::set<HostID>& changed_hosts, |
| 204 const std::vector<UserScript*>& scripts) override; | 204 const std::vector<UserScript*>& scripts) override; |
| 205 | 205 |
| 206 void UpdateActiveExtensions(); | 206 void UpdateActiveExtensions(); |
| 207 | 207 |
| 208 // Sets up the host permissions for |extension|. | 208 // Sets up the host permissions for |extension|. |
| 209 void InitOriginPermissions(const Extension* extension); | 209 void InitOriginPermissions(const Extension* extension); |
| 210 | 210 |
| 211 // Updates the host permissions for the extension url to include only those in | 211 // Updates the host permissions for the extension url to include only those in |
| 212 // |new_patterns|, and remove from |old_patterns| that are no longer allowed. | 212 // |new_patterns|, and remove from |old_patterns| that are no longer allowed. |
| 213 void UpdateOriginPermissions(const GURL& extension_url, | 213 void UpdateOriginPermissions(const GURL& extension_url, |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 323 | 323 |
| 324 // Status of webrequest usage. | 324 // Status of webrequest usage. |
| 325 bool webrequest_used_; | 325 bool webrequest_used_; |
| 326 | 326 |
| 327 DISALLOW_COPY_AND_ASSIGN(Dispatcher); | 327 DISALLOW_COPY_AND_ASSIGN(Dispatcher); |
| 328 }; | 328 }; |
| 329 | 329 |
| 330 } // namespace extensions | 330 } // namespace extensions |
| 331 | 331 |
| 332 #endif // EXTENSIONS_RENDERER_DISPATCHER_H_ | 332 #endif // EXTENSIONS_RENDERER_DISPATCHER_H_ |
| OLD | NEW |