Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2792)

Unified Diff: chrome/browser/ui/app_list/app_list_view_delegate.cc

Issue 12090062: Enable profile switching for standalone App Launcher via the Settings App. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: disable tests on aura Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/app_list/app_list_view_delegate.cc
diff --git a/chrome/browser/ui/app_list/app_list_view_delegate.cc b/chrome/browser/ui/app_list/app_list_view_delegate.cc
index 0a2d68db7305d87b5f424e9a1570c605ddd55358..6f1a2698fe87020a197e8e66173c1207698a1dc0 100644
--- a/chrome/browser/ui/app_list/app_list_view_delegate.cc
+++ b/chrome/browser/ui/app_list/app_list_view_delegate.cc
@@ -16,28 +16,30 @@
#include "chrome/browser/ui/ash/app_list/app_sync_ui_state_watcher.h"
#endif
-AppListViewDelegate::AppListViewDelegate(AppListControllerDelegate* controller)
- : controller_(controller) {}
+AppListViewDelegate::AppListViewDelegate(AppListControllerDelegate* controller,
+ Profile* profile)
+ : controller_(controller),
+ profile_(profile) {}
AppListViewDelegate::~AppListViewDelegate() {}
void AppListViewDelegate::SetModel(app_list::AppListModel* model) {
if (model) {
- Profile* profile = ProfileManager::GetDefaultProfileOrOffTheRecord();
- apps_builder_.reset(new AppsModelBuilder(profile,
+ apps_builder_.reset(new AppsModelBuilder(profile_,
model->apps(),
controller_.get()));
apps_builder_->Build();
- search_builder_.reset(new SearchBuilder(profile,
+ search_builder_.reset(new SearchBuilder(profile_,
model->search_box(),
model->results(),
controller_.get()));
- signin_delegate_.reset(new ChromeSigninDelegate(profile));
+ signin_delegate_.reset(new ChromeSigninDelegate(profile_));
#if defined(USE_ASH)
- app_sync_ui_state_watcher_.reset(new AppSyncUIStateWatcher(profile, model));
+ app_sync_ui_state_watcher_.reset(new AppSyncUIStateWatcher(profile_,
+ model));
#endif
} else {
apps_builder_.reset();
« no previous file with comments | « chrome/browser/ui/app_list/app_list_view_delegate.h ('k') | chrome/browser/ui/ash/app_list/app_list_controller_ash.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698