| 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 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 272 | 272 |
| 273 // Sets the active |permissions| for the extension with |extension_id|. | 273 // Sets the active |permissions| for the extension with |extension_id|. |
| 274 void SetActivePermissions(const std::string& extension_id, | 274 void SetActivePermissions(const std::string& extension_id, |
| 275 const extensions::PermissionSet* permissions); | 275 const extensions::PermissionSet* permissions); |
| 276 | 276 |
| 277 // Returns the list of events that the given extension has registered for. | 277 // Returns the list of events that the given extension has registered for. |
| 278 std::set<std::string> GetRegisteredEvents(const std::string& extension_id); | 278 std::set<std::string> GetRegisteredEvents(const std::string& extension_id); |
| 279 void SetRegisteredEvents(const std::string& extension_id, | 279 void SetRegisteredEvents(const std::string& extension_id, |
| 280 const std::set<std::string>& events); | 280 const std::set<std::string>& events); |
| 281 | 281 |
| 282 // Adds a filter to an event. |
| 283 void AddFilterToEvent(const std::string& event_name, |
| 284 const std::string& extension_id, |
| 285 const DictionaryValue* filter); |
| 286 |
| 287 // Removes a filter from an event. |
| 288 void RemoveFilterFromEvent(const std::string& event_name, |
| 289 const std::string& extension_id, |
| 290 const DictionaryValue* filter); |
| 291 |
| 292 // Returns the dictionary of event filters that the given extension has |
| 293 // registered. |
| 294 const DictionaryValue* GetFilteredEvents( |
| 295 const std::string& extension_id) const; |
| 296 |
| 282 // Controls the omnibox default suggestion as set by the extension. | 297 // Controls the omnibox default suggestion as set by the extension. |
| 283 extensions::ExtensionOmniboxSuggestion GetOmniboxDefaultSuggestion( | 298 extensions::ExtensionOmniboxSuggestion GetOmniboxDefaultSuggestion( |
| 284 const std::string& extension_id); | 299 const std::string& extension_id); |
| 285 void SetOmniboxDefaultSuggestion( | 300 void SetOmniboxDefaultSuggestion( |
| 286 const std::string& extension_id, | 301 const std::string& extension_id, |
| 287 const extensions::ExtensionOmniboxSuggestion& suggestion); | 302 const extensions::ExtensionOmniboxSuggestion& suggestion); |
| 288 | 303 |
| 289 // Returns true if the user enabled this extension to be loaded in incognito | 304 // Returns true if the user enabled this extension to be loaded in incognito |
| 290 // mode. | 305 // mode. |
| 291 bool IsIncognitoEnabled(const std::string& extension_id); | 306 bool IsIncognitoEnabled(const std::string& extension_id); |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 550 // Contains all the logic for handling the order for various extension | 565 // Contains all the logic for handling the order for various extension |
| 551 // properties. | 566 // properties. |
| 552 scoped_ptr<ExtensionSorting> extension_sorting_; | 567 scoped_ptr<ExtensionSorting> extension_sorting_; |
| 553 | 568 |
| 554 scoped_refptr<extensions::ContentSettingsStore> content_settings_store_; | 569 scoped_refptr<extensions::ContentSettingsStore> content_settings_store_; |
| 555 | 570 |
| 556 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); | 571 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); |
| 557 }; | 572 }; |
| 558 | 573 |
| 559 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 574 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| OLD | NEW |