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

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

Issue 1870793002: Convert //chrome/browser/chromeos from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: iwyu fixes Created 4 years, 8 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
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/app_launch_utils.h" 5 #include "chrome/browser/chromeos/app_mode/app_launch_utils.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "chrome/browser/chromeos/app_mode/kiosk_app_launch_error.h" 8 #include "chrome/browser/chromeos/app_mode/kiosk_app_launch_error.h"
9 #include "chrome/browser/chromeos/app_mode/startup_app_launcher.h" 9 #include "chrome/browser/chromeos/app_mode/startup_app_launcher.h"
10 #include "chrome/browser/lifetime/application_lifetime.h" 10 #include "chrome/browser/lifetime/application_lifetime.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 void OnInstallingApp() override {} 48 void OnInstallingApp() override {}
49 void OnReadyToLaunch() override { startup_app_launcher_->LaunchApp(); } 49 void OnReadyToLaunch() override { startup_app_launcher_->LaunchApp(); }
50 void OnLaunchSucceeded() override { Cleanup(); } 50 void OnLaunchSucceeded() override { Cleanup(); }
51 void OnLaunchFailed(KioskAppLaunchError::Error error) override { 51 void OnLaunchFailed(KioskAppLaunchError::Error error) override {
52 KioskAppLaunchError::Save(error); 52 KioskAppLaunchError::Save(error);
53 chrome::AttemptUserExit(); 53 chrome::AttemptUserExit();
54 Cleanup(); 54 Cleanup();
55 } 55 }
56 bool IsShowingNetworkConfigScreen() override { return false; } 56 bool IsShowingNetworkConfigScreen() override { return false; }
57 57
58 scoped_ptr<StartupAppLauncher> startup_app_launcher_; 58 std::unique_ptr<StartupAppLauncher> startup_app_launcher_;
59 59
60 DISALLOW_COPY_AND_ASSIGN(AppLaunchManager); 60 DISALLOW_COPY_AND_ASSIGN(AppLaunchManager);
61 }; 61 };
62 62
63 void LaunchAppOrDie(Profile* profile, const std::string& app_id) { 63 void LaunchAppOrDie(Profile* profile, const std::string& app_id) {
64 // AppLaunchManager manages its own lifetime. 64 // AppLaunchManager manages its own lifetime.
65 (new AppLaunchManager(profile, app_id))->Start(); 65 (new AppLaunchManager(profile, app_id))->Start();
66 } 66 }
67 67
68 } // namespace chromeos 68 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698