Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTERNAL_POLICY_EXTENSION_LOADER_H_ | |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTERNAL_POLICY_EXTENSION_LOADER_H_ | |
| 7 #pragma once | |
| 8 | |
| 9 #include "chrome/browser/extensions/external_extension_loader.h" | |
| 10 | |
| 11 #include "chrome/browser/prefs/pref_change_registrar.h" | |
| 12 #include "chrome/common/notification_observer.h" | |
| 13 #include "chrome/common/notification_registrar.h" | |
| 14 #include "chrome/common/notification_service.h" | |
| 15 #include "chrome/common/notification_type.h" | |
|
jochen (gone - plz use gerrit)
2011/01/04 12:38:01
why do you need _type and _service?
gfeher
2011/01/04 23:37:09
Done.
| |
| 16 | |
| 17 class ListValue; | |
| 18 class MockExternalPolicyExtensionProviderVisitor; | |
| 19 class Profile; | |
| 20 | |
| 21 // A specialization of the ExternalExtensionProvider that uses | |
| 22 // prefs::kExtensionInstallForceList to look up which external extensions are | |
| 23 // registered. | |
| 24 class ExternalPolicyExtensionLoader | |
| 25 : public ExternalExtensionLoader, | |
| 26 public NotificationObserver { | |
| 27 public: | |
| 28 explicit ExternalPolicyExtensionLoader(Profile* profile); | |
| 29 | |
| 30 // NotificationObserver | |
|
jochen (gone - plz use gerrit)
2011/01/04 12:38:01
... implementation.
gfeher
2011/01/04 23:37:09
Done.
| |
| 31 virtual void Observe(NotificationType type, | |
| 32 const NotificationSource& source, | |
| 33 const NotificationDetails& details); | |
| 34 | |
| 35 protected: | |
| 36 virtual void Load(); | |
| 37 | |
| 38 private: | |
| 39 friend class base::RefCountedThreadSafe<ExternalExtensionLoader>; | |
| 40 | |
| 41 virtual ~ExternalPolicyExtensionLoader() {} | |
| 42 | |
| 43 PrefChangeRegistrar pref_change_registrar_; | |
| 44 NotificationRegistrar notification_registrar_; | |
| 45 | |
| 46 Profile* profile_; | |
| 47 }; | |
|
jochen (gone - plz use gerrit)
2011/01/04 12:38:01
disallow copy and assign?
gfeher
2011/01/04 23:37:09
Done.
| |
| 48 | |
| 49 #endif // CHROME_BROWSER_EXTENSIONS_EXTERNAL_POLICY_EXTENSION_LOADER_H_ | |
| OLD | NEW |