| Index: chrome/browser/ui/app_list/app_list_service_impl.h
|
| diff --git a/chrome/browser/ui/app_list/app_list_service_impl.h b/chrome/browser/ui/app_list/app_list_service_impl.h
|
| index 878b5ea181323f457a5f239f136e2d145e61c790..566bc63e19ff836a4631f3d81c8c01c59f7b5bda 100644
|
| --- a/chrome/browser/ui/app_list/app_list_service_impl.h
|
| +++ b/chrome/browser/ui/app_list/app_list_service_impl.h
|
| @@ -13,8 +13,11 @@
|
| #include "base/memory/weak_ptr.h"
|
| #include "chrome/browser/profiles/profile.h"
|
| #include "chrome/browser/profiles/profile_info_cache_observer.h"
|
| -#include "chrome/browser/profiles/profile_loader.h"
|
| #include "chrome/browser/ui/app_list/app_list_service.h"
|
| +#include "chrome/browser/ui/app_list/keep_alive_service.h"
|
| +#include "chrome/browser/ui/app_list/profile_loader.h"
|
| +
|
| +class ProfileStore;
|
|
|
| namespace base {
|
| class FilePath;
|
| @@ -26,16 +29,19 @@ class AppListServiceImpl : public AppListService,
|
| public:
|
| static void RecordAppListLaunch();
|
| static void RecordAppListAppLaunch();
|
| + virtual ~AppListServiceImpl();
|
|
|
| - protected:
|
| AppListServiceImpl();
|
| - virtual ~AppListServiceImpl();
|
| + // Constructor used for testing.
|
| + AppListServiceImpl(PrefService* local_state,
|
| + scoped_ptr<ProfileStore> profile_store,
|
| + scoped_ptr<KeepAliveService> keep_alive_service);
|
|
|
| Profile* profile() const { return profile_; }
|
| void SetProfile(Profile* new_profile);
|
| void InvalidatePendingProfileLoads();
|
| - ProfileLoader& profile_loader() { return profile_loader_; }
|
| - const ProfileLoader& profile_loader() const { return profile_loader_; }
|
| + ProfileLoader& profile_loader() { return *profile_loader_; }
|
| + const ProfileLoader& profile_loader() const { return *profile_loader_; }
|
|
|
| // Process command line flags shared between desktop implementations of the
|
| // app list. Currently this allows for enabling or disabling the app list.
|
| @@ -76,16 +82,12 @@ class AppListServiceImpl : public AppListService,
|
|
|
| // The profile the AppList is currently displaying.
|
| Profile* profile_;
|
| -
|
| - // Incremented to indicate that pending profile loads are no longer valid.
|
| - int profile_load_sequence_id_;
|
| -
|
| - // How many profile loads are pending.
|
| - int pending_profile_loads_;
|
| + scoped_ptr<ProfileStore> profile_store_;
|
|
|
| base::WeakPtrFactory<AppListServiceImpl> weak_factory_;
|
|
|
| - ProfileLoader profile_loader_;
|
| + PrefService* local_state_;
|
| + scoped_ptr<ProfileLoader> profile_loader_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(AppListServiceImpl);
|
| };
|
|
|