Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 68 class Profile; | 68 class Profile; |
| 69 class SyncData; | 69 class SyncData; |
| 70 class Version; | 70 class Version; |
| 71 | 71 |
| 72 namespace chromeos { | 72 namespace chromeos { |
| 73 class ExtensionInputMethodEventRouter; | 73 class ExtensionInputMethodEventRouter; |
| 74 } // namespace chromeos | 74 } // namespace chromeos |
| 75 | 75 |
| 76 // This is an interface class to encapsulate the dependencies that | 76 // This is an interface class to encapsulate the dependencies that |
| 77 // various classes have on ExtensionService. This allows easy mocking. | 77 // various classes have on ExtensionService. This allows easy mocking. |
| 78 class ExtensionServiceInterface : public SyncableService { | 78 class ExtensionServiceInterface |
| 79 : public SyncableService, | |
| 80 public base::SupportsWeakPtr<ExtensionServiceInterface> { | |
|
akalin
2011/10/12 19:54:21
can you stick this onto the actual ExtensionServic
Nicolas Zea
2011/10/12 23:47:43
Discussed offline. Sticking with SyncableService i
| |
| 79 public: | 81 public: |
| 80 // A function that returns true if the given extension should be | 82 // A function that returns true if the given extension should be |
| 81 // included and false if it should be filtered out. Identical to | 83 // included and false if it should be filtered out. Identical to |
| 82 // PendingExtensionInfo::ShouldAllowInstallPredicate. | 84 // PendingExtensionInfo::ShouldAllowInstallPredicate. |
| 83 typedef bool (*ExtensionFilter)(const Extension&); | 85 typedef bool (*ExtensionFilter)(const Extension&); |
| 84 | 86 |
| 85 virtual ~ExtensionServiceInterface() {} | 87 virtual ~ExtensionServiceInterface() {} |
| 86 virtual const ExtensionList* extensions() const = 0; | 88 virtual const ExtensionList* extensions() const = 0; |
| 87 virtual PendingExtensionManager* pending_extension_manager() = 0; | 89 virtual PendingExtensionManager* pending_extension_manager() = 0; |
| 88 | 90 |
| (...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 826 ExtensionWarningSet extension_warnings_; | 828 ExtensionWarningSet extension_warnings_; |
| 827 | 829 |
| 828 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, | 830 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, |
| 829 InstallAppsWithUnlimtedStorage); | 831 InstallAppsWithUnlimtedStorage); |
| 830 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, | 832 FRIEND_TEST_ALL_PREFIXES(ExtensionServiceTest, |
| 831 InstallAppsAndCheckStorageProtection); | 833 InstallAppsAndCheckStorageProtection); |
| 832 DISALLOW_COPY_AND_ASSIGN(ExtensionService); | 834 DISALLOW_COPY_AND_ASSIGN(ExtensionService); |
| 833 }; | 835 }; |
| 834 | 836 |
| 835 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ | 837 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SERVICE_H_ |
| OLD | NEW |