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 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 411 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
422 // Clears incognito session-only content settings for all extensions. | 422 // Clears incognito session-only content settings for all extensions. |
423 void ClearIncognitoSessionOnlyContentSettings(); | 423 void ClearIncognitoSessionOnlyContentSettings(); |
424 | 424 |
425 // Returns true if the extension was installed from the Chrome Web Store. | 425 // Returns true if the extension was installed from the Chrome Web Store. |
426 bool IsFromWebStore(const std::string& extension_id) const; | 426 bool IsFromWebStore(const std::string& extension_id) const; |
427 | 427 |
428 // Returns true if the extension was installed from an App generated from a | 428 // Returns true if the extension was installed from an App generated from a |
429 // bookmark. | 429 // bookmark. |
430 bool IsFromBookmark(const std::string& extension_id) const; | 430 bool IsFromBookmark(const std::string& extension_id) const; |
431 | 431 |
| 432 // Returns true if the extension was installed as a default app. |
| 433 bool WasInstalledByDefault(const std::string& extension_id) const; |
| 434 |
432 // Helper method to acquire the installation time of an extension. | 435 // Helper method to acquire the installation time of an extension. |
433 // Returns base::Time() if the installation time could not be parsed or | 436 // Returns base::Time() if the installation time could not be parsed or |
434 // found. | 437 // found. |
435 base::Time GetInstallTime(const std::string& extension_id) const; | 438 base::Time GetInstallTime(const std::string& extension_id) const; |
436 | 439 |
437 static void RegisterUserPrefs(PrefService* prefs); | 440 static void RegisterUserPrefs(PrefService* prefs); |
438 | 441 |
439 ContentSettingsStore* content_settings_store() { | 442 ContentSettingsStore* content_settings_store() { |
440 return content_settings_store_.get(); | 443 return content_settings_store_.get(); |
441 } | 444 } |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
562 scoped_ptr<ExtensionSorting> extension_sorting_; | 565 scoped_ptr<ExtensionSorting> extension_sorting_; |
563 | 566 |
564 scoped_refptr<ContentSettingsStore> content_settings_store_; | 567 scoped_refptr<ContentSettingsStore> content_settings_store_; |
565 | 568 |
566 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); | 569 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); |
567 }; | 570 }; |
568 | 571 |
569 } // namespace extensions | 572 } // namespace extensions |
570 | 573 |
571 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 574 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
OLD | NEW |