| 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_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ | 5 #ifndef CHROME_BROWSER_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ |
| 6 #define CHROME_BROWSER_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ | 6 #define CHROME_BROWSER_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| 11 | 11 |
| 12 #include "base/basictypes.h" | 12 #include "base/basictypes.h" |
| 13 #include "base/observer_list.h" | 13 #include "base/observer_list.h" |
| 14 #include "chrome/common/extensions/extension.h" | 14 #include "chrome/common/extensions/extension.h" |
| 15 #include "content/public/browser/notification_observer.h" | 15 #include "content/public/browser/notification_observer.h" |
| 16 #include "content/public/browser/notification_registrar.h" | 16 #include "content/public/browser/notification_registrar.h" |
| 17 | 17 |
| 18 class ExtensionService; | |
| 19 class PrefService; | |
| 20 class Profile; | 18 class Profile; |
| 21 | 19 |
| 22 // Model for list of Background Applications, that is, Extensions with | 20 // Model for list of Background Applications, that is, Extensions with |
| 23 // kBackgroundPermission set, associated with a Profile. | 21 // kBackgroundPermission set, associated with a Profile. |
| 24 class BackgroundApplicationListModel : public content::NotificationObserver { | 22 class BackgroundApplicationListModel : public content::NotificationObserver { |
| 25 public: | 23 public: |
| 26 // Observer is informed of changes to the model. Users of the | 24 // Observer is informed of changes to the model. Users of the |
| 27 // BackgroundApplicationListModel should anticipate that associated data, | 25 // BackgroundApplicationListModel should anticipate that associated data, |
| 28 // e. g. the Icon, may exist and yet not be immediately available. When the | 26 // e. g. the Icon, may exist and yet not be immediately available. When the |
| 29 // data becomes available, OnApplicationDataChanged will be invoked for all | 27 // data becomes available, OnApplicationDataChanged will be invoked for all |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 ApplicationMap applications_; | 133 ApplicationMap applications_; |
| 136 ExtensionList extensions_; | 134 ExtensionList extensions_; |
| 137 ObserverList<Observer> observers_; | 135 ObserverList<Observer> observers_; |
| 138 Profile* profile_; | 136 Profile* profile_; |
| 139 content::NotificationRegistrar registrar_; | 137 content::NotificationRegistrar registrar_; |
| 140 | 138 |
| 141 DISALLOW_COPY_AND_ASSIGN(BackgroundApplicationListModel); | 139 DISALLOW_COPY_AND_ASSIGN(BackgroundApplicationListModel); |
| 142 }; | 140 }; |
| 143 | 141 |
| 144 #endif // CHROME_BROWSER_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ | 142 #endif // CHROME_BROWSER_BACKGROUND_BACKGROUND_APPLICATION_LIST_MODEL_H_ |
| OLD | NEW |