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

Side by Side Diff: chrome/browser/chromeos/app_mode/startup_app_launcher.cc

Issue 106713002: Move LaunchContainer enum to extension_constants.h. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 7 years 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 | Annotate | Revision Log
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/chromeos/app_mode/startup_app_launcher.h" 5 #include "chrome/browser/chromeos/app_mode/startup_app_launcher.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/json/json_file_value_serializer.h" 9 #include "base/json/json_file_value_serializer.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 extension_service()->GetInstalledExtension(app_id_); 204 extension_service()->GetInstalledExtension(app_id_);
205 CHECK(extension); 205 CHECK(extension);
206 206
207 if (!extensions::KioskModeInfo::IsKioskEnabled(extension)) { 207 if (!extensions::KioskModeInfo::IsKioskEnabled(extension)) {
208 OnLaunchFailure(KioskAppLaunchError::NOT_KIOSK_ENABLED); 208 OnLaunchFailure(KioskAppLaunchError::NOT_KIOSK_ENABLED);
209 return; 209 return;
210 } 210 }
211 211
212 // Always open the app in a window. 212 // Always open the app in a window.
213 OpenApplication(AppLaunchParams(profile_, extension, 213 OpenApplication(AppLaunchParams(profile_, extension,
214 extensions::LAUNCH_WINDOW, NEW_WINDOW)); 214 extensions::LAUNCH_CONTAINER_WINDOW,
215 NEW_WINDOW));
215 InitAppSession(profile_, app_id_); 216 InitAppSession(profile_, app_id_);
216 217
217 UserManager::Get()->SessionStarted(); 218 UserManager::Get()->SessionStarted();
218 219
219 content::NotificationService::current()->Notify( 220 content::NotificationService::current()->Notify(
220 chrome::NOTIFICATION_KIOSK_APP_LAUNCHED, 221 chrome::NOTIFICATION_KIOSK_APP_LAUNCHED,
221 content::NotificationService::AllSources(), 222 content::NotificationService::AllSources(),
222 content::NotificationService::NoDetails()); 223 content::NotificationService::NoDetails());
223 224
224 OnLaunchSuccess(); 225 OnLaunchSuccess();
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 LOG(ERROR) << "App install failed: " << error; 258 LOG(ERROR) << "App install failed: " << error;
258 OnLaunchFailure(KioskAppLaunchError::UNABLE_TO_INSTALL); 259 OnLaunchFailure(KioskAppLaunchError::UNABLE_TO_INSTALL);
259 } 260 }
260 261
261 void StartupAppLauncher::OnReadyToLaunch() { 262 void StartupAppLauncher::OnReadyToLaunch() {
262 ready_to_launch_ = true; 263 ready_to_launch_ = true;
263 delegate_->OnReadyToLaunch(); 264 delegate_->OnReadyToLaunch();
264 } 265 }
265 266
266 } // namespace chromeos 267 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/automation/testing_automation_provider.cc ('k') | chrome/browser/chromeos/extensions/wallpaper_manager_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698