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

Unified Diff: chrome/browser/ui/ash/launcher/launcher_controller_helper.cc

Issue 2684723003: Remove LauncherItemController::Launch, cleanup. (Closed)
Patch Set: Use AppLauncherId Created 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/ash/launcher/launcher_controller_helper.cc
diff --git a/chrome/browser/ui/ash/launcher/launcher_controller_helper.cc b/chrome/browser/ui/ash/launcher/launcher_controller_helper.cc
index 28a0ee2994f429e9055f2b3b96818b73b64689a7..4d0cf7d8b5f7b287567f89fd813e2b62420dbb3f 100644
--- a/chrome/browser/ui/ash/launcher/launcher_controller_helper.cc
+++ b/chrome/browser/ui/ash/launcher/launcher_controller_helper.cc
@@ -169,17 +169,10 @@ bool LauncherControllerHelper::IsValidIDForCurrentUser(
return true;
}
-void LauncherControllerHelper::LaunchApp(const std::string& app_id,
+void LauncherControllerHelper::LaunchApp(ash::launcher::AppLauncherId id,
ash::LaunchSource source,
int event_flags) {
- LaunchAppWithLaunchId(app_id, "", source, event_flags);
-}
-
-void LauncherControllerHelper::LaunchAppWithLaunchId(
- const std::string& app_id,
- const std::string& launch_id,
- ash::LaunchSource source,
- int event_flags) {
+ const std::string& app_id = id.app_id();
const ArcAppListPrefs* arc_prefs = GetArcAppListPrefs();
if (arc_prefs && arc_prefs->IsRegistered(app_id)) {
arc::LaunchApp(profile_, app_id, event_flags);
@@ -215,7 +208,7 @@ void LauncherControllerHelper::LaunchAppWithLaunchId(
params.override_url = net::AppendQueryParameter(
extension_url, extension_urls::kWebstoreSourceField, source_value);
}
- params.launch_id = launch_id;
+ params.launch_id = id.launch_id();
OpenApplication(params);
}
@@ -225,8 +218,9 @@ ArcAppListPrefs* LauncherControllerHelper::GetArcAppListPrefs() const {
}
void LauncherControllerHelper::ExtensionEnableFlowFinished() {
- LaunchApp(extension_enable_flow_->extension_id(), ash::LAUNCH_FROM_UNKNOWN,
- ui::EF_NONE);
+ LaunchApp(
+ ash::launcher::AppLauncherId(extension_enable_flow_->extension_id()),
+ ash::LAUNCH_FROM_UNKNOWN, ui::EF_NONE);
extension_enable_flow_.reset();
}
« no previous file with comments | « chrome/browser/ui/ash/launcher/launcher_controller_helper.h ('k') | chrome/browser/ui/ash/launcher/launcher_item_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698