| 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 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 268 | 268 |
| 269 // Sets the active |permissions| for the extension with |extension_id|. | 269 // Sets the active |permissions| for the extension with |extension_id|. |
| 270 void SetActivePermissions(const std::string& extension_id, | 270 void SetActivePermissions(const std::string& extension_id, |
| 271 const ExtensionPermissionSet* permissions); | 271 const ExtensionPermissionSet* permissions); |
| 272 | 272 |
| 273 // Returns the list of events that the given extension has registered for. | 273 // Returns the list of events that the given extension has registered for. |
| 274 std::set<std::string> GetRegisteredEvents(const std::string& extension_id); | 274 std::set<std::string> GetRegisteredEvents(const std::string& extension_id); |
| 275 void SetRegisteredEvents(const std::string& extension_id, | 275 void SetRegisteredEvents(const std::string& extension_id, |
| 276 const std::set<std::string>& events); | 276 const std::set<std::string>& events); |
| 277 | 277 |
| 278 // Adds a filter to an event. | |
| 279 void AddFilterToEvent(const std::string& event_name, | |
| 280 const std::string& extension_id, | |
| 281 const DictionaryValue* filter); | |
| 282 | |
| 283 // Removes a filter from an event. | |
| 284 void RemoveFilterFromEvent(const std::string& event_name, | |
| 285 const std::string& extension_id, | |
| 286 const DictionaryValue* filter); | |
| 287 | |
| 288 // Returns the dictionary of event filters that the given extension has | |
| 289 // registered. | |
| 290 const DictionaryValue* GetFilteredEvents( | |
| 291 const std::string& extension_id) const; | |
| 292 | |
| 293 // Controls the omnibox default suggestion as set by the extension. | 278 // Controls the omnibox default suggestion as set by the extension. |
| 294 extensions::ExtensionOmniboxSuggestion GetOmniboxDefaultSuggestion( | 279 extensions::ExtensionOmniboxSuggestion GetOmniboxDefaultSuggestion( |
| 295 const std::string& extension_id); | 280 const std::string& extension_id); |
| 296 void SetOmniboxDefaultSuggestion( | 281 void SetOmniboxDefaultSuggestion( |
| 297 const std::string& extension_id, | 282 const std::string& extension_id, |
| 298 const extensions::ExtensionOmniboxSuggestion& suggestion); | 283 const extensions::ExtensionOmniboxSuggestion& suggestion); |
| 299 | 284 |
| 300 // Returns true if the user enabled this extension to be loaded in incognito | 285 // Returns true if the user enabled this extension to be loaded in incognito |
| 301 // mode. | 286 // mode. |
| 302 bool IsIncognitoEnabled(const std::string& extension_id); | 287 bool IsIncognitoEnabled(const std::string& extension_id); |
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 557 // Contains all the logic for handling the order for various extension | 542 // Contains all the logic for handling the order for various extension |
| 558 // properties. | 543 // properties. |
| 559 scoped_ptr<ExtensionSorting> extension_sorting_; | 544 scoped_ptr<ExtensionSorting> extension_sorting_; |
| 560 | 545 |
| 561 scoped_refptr<extensions::ContentSettingsStore> content_settings_store_; | 546 scoped_refptr<extensions::ContentSettingsStore> content_settings_store_; |
| 562 | 547 |
| 563 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); | 548 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); |
| 564 }; | 549 }; |
| 565 | 550 |
| 566 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 551 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| OLD | NEW |