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

Unified Diff: chrome/browser/ui/views/app_list/win/app_list_service_win.cc

Issue 210083009: Add a whole-app-list unit test. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove unused function Created 6 years, 7 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/views/app_list/win/app_list_service_win.cc
diff --git a/chrome/browser/ui/views/app_list/win/app_list_service_win.cc b/chrome/browser/ui/views/app_list/win/app_list_service_win.cc
index b213b93be0f63eb291e5478b678da1c237e00569..dc0faee3ef12a17063c1d621838d7a9976d8cb15 100644
--- a/chrome/browser/ui/views/app_list/win/app_list_service_win.cc
+++ b/chrome/browser/ui/views/app_list/win/app_list_service_win.cc
@@ -276,7 +276,9 @@ void AppListServiceWin::OnLoadProfileForWarmup(Profile* initial_profile) {
}
void AppListServiceWin::SetAppListNextPaintCallback(void (*callback)()) {
- app_list::AppListView::SetNextPaintCallback(callback);
+ // This should only be called during startup.
+ DCHECK(!shower().app_list());
+ next_paint_callback_ = base::Bind(callback);
}
void AppListServiceWin::HandleFirstRun() {
@@ -364,6 +366,10 @@ void AppListServiceWin::OnViewBeingDestroyed() {
}
void AppListServiceWin::OnViewCreated() {
+ if (!next_paint_callback_.is_null()) {
+ shower().app_list()->SetNextPaintCallback(next_paint_callback_);
+ next_paint_callback_.Reset();
+ }
SetWindowAttributes(shower().app_list()->GetHWND());
activation_tracker_.reset(new ActivationTrackerWin(this));
}

Powered by Google App Engine
This is Rietveld 408576698