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

Side by Side Diff: chrome/browser/chromeos/login/app_launch_controller.cc

Issue 156493004: Add the ability to show a demo app on OOBE if a machine is derelict. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 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/login/app_launch_controller.h" 5 #include "chrome/browser/chromeos/login/app_launch_controller.h"
6 6
7 #include "apps/shell_window_registry.h" 7 #include "apps/shell_window_registry.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/json/json_file_value_serializer.h" 10 #include "base/json/json_file_value_serializer.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 if (!webui_visible_) { 113 if (!webui_visible_) {
114 registrar_.Add(this, chrome::NOTIFICATION_LOGIN_OR_LOCK_WEBUI_VISIBLE, 114 registrar_.Add(this, chrome::NOTIFICATION_LOGIN_OR_LOCK_WEBUI_VISIBLE,
115 content::NotificationService::AllSources()); 115 content::NotificationService::AllSources());
116 } 116 }
117 launch_splash_start_time_ = base::TimeTicks::Now().ToInternalValue(); 117 launch_splash_start_time_ = base::TimeTicks::Now().ToInternalValue();
118 118
119 // TODO(tengs): Add a loading profile app launch state. 119 // TODO(tengs): Add a loading profile app launch state.
120 app_launch_splash_screen_actor_->SetDelegate(this); 120 app_launch_splash_screen_actor_->SetDelegate(this);
121 app_launch_splash_screen_actor_->Show(app_id_); 121 app_launch_splash_screen_actor_->Show(app_id_);
122 122
123 kiosk_profile_loader_.reset( 123 KioskAppManager::App app;
124 new KioskProfileLoader(KioskAppManager::Get(), app_id_, this)); 124 CHECK(KioskAppManager::Get() &&
125 KioskAppManager::Get()->GetApp(app_id_, &app));
126 kiosk_profile_loader_.reset(new KioskProfileLoader(app.user_id, this));
125 kiosk_profile_loader_->Start(); 127 kiosk_profile_loader_->Start();
126 } 128 }
127 129
128 // static 130 // static
129 void AppLaunchController::SkipSplashWaitForTesting() { 131 void AppLaunchController::SkipSplashWaitForTesting() {
130 skip_splash_wait_ = true; 132 skip_splash_wait_ = true;
131 } 133 }
132 134
133 // static 135 // static
134 void AppLaunchController::SetNetworkWaitForTesting(int wait_time_secs) { 136 void AppLaunchController::SetNetworkWaitForTesting(int wait_time_secs) {
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 << ", error=" << error; 371 << ", error=" << error;
370 DCHECK_NE(KioskAppLaunchError::NONE, error); 372 DCHECK_NE(KioskAppLaunchError::NONE, error);
371 373
372 // Saves the error and ends the session to go back to login screen. 374 // Saves the error and ends the session to go back to login screen.
373 KioskAppLaunchError::Save(error); 375 KioskAppLaunchError::Save(error);
374 chrome::AttemptUserExit(); 376 chrome::AttemptUserExit();
375 CleanUp(); 377 CleanUp();
376 } 378 }
377 379
378 } // namespace chromeos 380 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698