Chromium Code Reviews| Index: apps/launcher.cc |
| diff --git a/apps/launcher.cc b/apps/launcher.cc |
| index 1ac5aef27947de679163f78d81d4f6998fe81ea3..9dc0e12fe827cecbe5bb44570df02c770569ada5 100644 |
| --- a/apps/launcher.cc |
| +++ b/apps/launcher.cc |
| @@ -363,6 +363,19 @@ void LaunchPlatformAppWithCommandLine(Profile* profile, |
| const base::FilePath& current_directory, |
| extensions::AppLaunchSource source, |
| PlayStoreStatus play_store_status) { |
| + LaunchPlatformAppWithCommandLineAndLaunchId(profile, app, "", command_line, |
| + current_directory, source, |
| + play_store_status); |
| +} |
| + |
| +void LaunchPlatformAppWithCommandLineAndLaunchId( |
| + Profile* profile, |
| + const extensions::Extension* app, |
| + const std::string& launch_id, |
| + const base::CommandLine& command_line, |
| + const base::FilePath& current_directory, |
| + extensions::AppLaunchSource source, |
| + PlayStoreStatus play_store_status) { |
| // An app with "kiosk_only" should not be installed and launched |
| // outside of ChromeOS kiosk mode in the first place. This is a defensive |
| // check in case this scenario does occur. |
| @@ -374,7 +387,7 @@ void LaunchPlatformAppWithCommandLine(Profile* profile, |
| #endif |
| if (!in_kiosk_mode) { |
| LOG(ERROR) << "App with 'kiosk_only' attribute must be run in " |
| - << " ChromeOS kiosk mode."; |
| + << " ChromeOS kiosk mode."; |
| NOTREACHED(); |
| return; |
| } |
| @@ -397,6 +410,7 @@ void LaunchPlatformAppWithCommandLine(Profile* profile, |
| base::MakeUnique<app_runtime::LaunchData>(); |
| if (play_store_status != PlayStoreStatus::PLAY_STORE_STATUS_UNKNOWN) |
| launch_data->play_store_status = play_store_status; |
| + launch_data->id.reset(new std::string(launch_id)); |
|
stevenjb
2016/12/09 17:00:56
Rather than potentially allocating an empty string
Andra Paraschiv
2016/12/12 14:28:22
Done.
|
| AppRuntimeEventRouter::DispatchOnLaunchedEvent(profile, app, source, |
| std::move(launch_data)); |
| return; |