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

Side by Side Diff: chrome/browser/chromeos/login/users/wallpaper/wallpaper_manager_browsertest.cc

Issue 2393083005: Moves Shell::CreateShelf() to WmShell (Closed)
Patch Set: fix shell Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « ash/test/test_session_state_delegate.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/chromeos/login/users/wallpaper/wallpaper_manager.h" 5 #include "chrome/browser/chromeos/login/users/wallpaper/wallpaper_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "ash/common/wallpaper/wallpaper_controller.h" 9 #include "ash/common/wallpaper/wallpaper_controller.h"
10 #include "ash/common/wm_shell.h" 10 #include "ash/common/wm_shell.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 111
112 return wallpaper_path; 112 return wallpaper_path;
113 } 113 }
114 114
115 // Logs in |account_id|. 115 // Logs in |account_id|.
116 void LogIn(const AccountId& account_id, const std::string& user_id_hash) { 116 void LogIn(const AccountId& account_id, const std::string& user_id_hash) {
117 user_manager::UserManager::Get()->UserLoggedIn(account_id, user_id_hash, 117 user_manager::UserManager::Get()->UserLoggedIn(account_id, user_id_hash,
118 false); 118 false);
119 // Adding a secondary display creates a shelf on that display, which 119 // Adding a secondary display creates a shelf on that display, which
120 // assumes a shelf on the primary display if the user was logged in. 120 // assumes a shelf on the primary display if the user was logged in.
121 ash::Shell::GetInstance()->CreateShelf(); 121 ash::WmShell::Get()->CreateShelf();
122 WaitAsyncWallpaperLoadStarted(); 122 WaitAsyncWallpaperLoadStarted();
123 } 123 }
124 124
125 // Logs in |account_id| and sets it as child account. 125 // Logs in |account_id| and sets it as child account.
126 void LogInAsChild(const AccountId& account_id, 126 void LogInAsChild(const AccountId& account_id,
127 const std::string& user_id_hash) { 127 const std::string& user_id_hash) {
128 user_manager::UserManager::Get()->UserLoggedIn(account_id, user_id_hash, 128 user_manager::UserManager::Get()->UserLoggedIn(account_id, user_id_hash,
129 false); 129 false);
130 user_manager::User* user = 130 user_manager::User* user =
131 user_manager::UserManager::Get()->FindUserAndModify(account_id); 131 user_manager::UserManager::Get()->FindUserAndModify(account_id);
(...skipping 713 matching lines...) Expand 10 before | Expand all | Expand 10 after
845 845
846 WallpaperManager::Get()->SetDefaultWallpaperNow(EmptyAccountId()); 846 WallpaperManager::Get()->SetDefaultWallpaperNow(EmptyAccountId());
847 wallpaper_manager_test_utils::WaitAsyncWallpaperLoadFinished(); 847 wallpaper_manager_test_utils::WaitAsyncWallpaperLoadFinished();
848 848
849 EXPECT_TRUE(wallpaper_manager_test_utils::ImageIsNearColor( 849 EXPECT_TRUE(wallpaper_manager_test_utils::ImageIsNearColor(
850 controller_->GetWallpaper(), 850 controller_->GetWallpaper(),
851 wallpaper_manager_test_utils::kSmallDefaultWallpaperColor)); 851 wallpaper_manager_test_utils::kSmallDefaultWallpaperColor));
852 } 852 }
853 853
854 } // namespace chromeos 854 } // namespace chromeos
OLDNEW
« no previous file with comments | « ash/test/test_session_state_delegate.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698