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 #include "chrome/browser/ui/app_list/app_list_controller_delegate.h" | 5 #include "chrome/browser/ui/app_list/app_list_controller_delegate.h" |
6 | 6 |
7 #include "chrome/browser/extensions/extension_service.h" | 7 #include "chrome/browser/extensions/extension_service.h" |
8 #include "chrome/browser/extensions/extension_system.h" | 8 #include "chrome/browser/extensions/extension_system.h" |
9 #include "chrome/browser/extensions/install_tracker_factory.h" | 9 #include "chrome/browser/extensions/install_tracker_factory.h" |
10 #include "chrome/browser/extensions/management_policy.h" | 10 #include "chrome/browser/extensions/management_policy.h" |
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 Profile* profile) { | 154 Profile* profile) { |
155 if (extensions::ExtensionSystem::Get(profile)->extension_service()) | 155 if (extensions::ExtensionSystem::Get(profile)->extension_service()) |
156 return extensions::InstallTrackerFactory::GetForProfile(profile); | 156 return extensions::InstallTrackerFactory::GetForProfile(profile); |
157 return NULL; | 157 return NULL; |
158 } | 158 } |
159 | 159 |
160 void AppListControllerDelegate::GetApps(Profile* profile, | 160 void AppListControllerDelegate::GetApps(Profile* profile, |
161 ExtensionSet* out_apps) { | 161 ExtensionSet* out_apps) { |
162 ExtensionService* service = | 162 ExtensionService* service = |
163 extensions::ExtensionSystem::Get(profile)->extension_service(); | 163 extensions::ExtensionSystem::Get(profile)->extension_service(); |
164 if (!service) | 164 DCHECK(service); |
165 return; | |
166 out_apps->InsertAll(*service->extensions()); | 165 out_apps->InsertAll(*service->extensions()); |
167 out_apps->InsertAll(*service->disabled_extensions()); | 166 out_apps->InsertAll(*service->disabled_extensions()); |
168 out_apps->InsertAll(*service->terminated_extensions()); | 167 out_apps->InsertAll(*service->terminated_extensions()); |
169 } | 168 } |
OLD | NEW |