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

Side by Side Diff: chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc

Issue 2507073002: Split ArcSessionManager from ArcAuthService. (Closed)
Patch Set: Split ArcSessionManager from ArcAuthService Created 4 years, 1 month 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/ash/launcher/chrome_launcher_controller.h" 5 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h"
6 6
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "chrome/browser/extensions/extension_app_icon_loader.h" 8 #include "chrome/browser/extensions/extension_app_icon_loader.h"
9 #include "chrome/browser/profiles/profile_manager.h" 9 #include "chrome/browser/profiles/profile_manager.h"
10 #include "chrome/browser/ui/app_list/arc/arc_app_icon_loader.h" 10 #include "chrome/browser/ui/app_list/arc/arc_app_icon_loader.h"
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 // TODO(skuhne): The AppIconLoaderImpl has the same problem. Each loaded 133 // TODO(skuhne): The AppIconLoaderImpl has the same problem. Each loaded
134 // image is associated with a profile (its loader requires the profile). 134 // image is associated with a profile (its loader requires the profile).
135 // Since icon size changes are possible, the icon could be requested to be 135 // Since icon size changes are possible, the icon could be requested to be
136 // reloaded. However - having it not multi profile aware would cause problems 136 // reloaded. However - having it not multi profile aware would cause problems
137 // if the icon cache gets deleted upon user switch. 137 // if the icon cache gets deleted upon user switch.
138 std::unique_ptr<AppIconLoader> extension_app_icon_loader = 138 std::unique_ptr<AppIconLoader> extension_app_icon_loader =
139 base::MakeUnique<extensions::ExtensionAppIconLoader>( 139 base::MakeUnique<extensions::ExtensionAppIconLoader>(
140 profile_, extension_misc::EXTENSION_ICON_SMALL, this); 140 profile_, extension_misc::EXTENSION_ICON_SMALL, this);
141 app_icon_loaders_.push_back(std::move(extension_app_icon_loader)); 141 app_icon_loaders_.push_back(std::move(extension_app_icon_loader));
142 142
143 if (arc::ArcAuthService::IsAllowedForProfile(profile_)) { 143 if (arc::ArcSessionManager::IsAllowedForProfile(profile_)) {
144 std::unique_ptr<AppIconLoader> arc_app_icon_loader = 144 std::unique_ptr<AppIconLoader> arc_app_icon_loader =
145 base::MakeUnique<ArcAppIconLoader>( 145 base::MakeUnique<ArcAppIconLoader>(
146 profile_, extension_misc::EXTENSION_ICON_SMALL, this); 146 profile_, extension_misc::EXTENSION_ICON_SMALL, this);
147 app_icon_loaders_.push_back(std::move(arc_app_icon_loader)); 147 app_icon_loaders_.push_back(std::move(arc_app_icon_loader));
148 } 148 }
149 } 149 }
150 150
151 void ChromeLauncherController::OnShelfCreated(int64_t display_id) { 151 void ChromeLauncherController::OnShelfCreated(int64_t display_id) {
152 if (!ConnectToShelfController()) 152 if (!ConnectToShelfController())
153 return; 153 return;
(...skipping 25 matching lines...) Expand all
179 // TODO(msw): Avoid handling this pref change and forwarding the value to ash. 179 // TODO(msw): Avoid handling this pref change and forwarding the value to ash.
180 ash::launcher::SetShelfAutoHideBehaviorPref(profile_->GetPrefs(), display_id, 180 ash::launcher::SetShelfAutoHideBehaviorPref(profile_->GetPrefs(), display_id,
181 auto_hide); 181 auto_hide);
182 } 182 }
183 183
184 void ChromeLauncherController::OnAppImageUpdated(const std::string& app_id, 184 void ChromeLauncherController::OnAppImageUpdated(const std::string& app_id,
185 const gfx::ImageSkia& image) { 185 const gfx::ImageSkia& image) {
186 // Implemented by subclasses; this should not be called. 186 // Implemented by subclasses; this should not be called.
187 NOTREACHED(); 187 NOTREACHED();
188 } 188 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698