Launch kiosk apps from Login screen "Apps" menu.
Bug: 836861
Change-Id: Ib480dfa25b45a1cc6dd1424e8f84d0891eec1a0e
Reviewed-on: https://chromium-review.googlesource.com/1092095
Commit-Queue: Quan Nguyen <qnnguyen@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Xiyuan Xia <xiyuan@chromium.org>
Reviewed-by: Jacob Dufault <jdufault@chromium.org>
Cr-Commit-Position: refs/heads/master@{#568560}
diff --git a/ash/login/login_screen_controller.cc b/ash/login/login_screen_controller.cc
index 07b62462..46c6679 100644
--- a/ash/login/login_screen_controller.cc
+++ b/ash/login/login_screen_controller.cc
@@ -5,10 +5,13 @@
#include "ash/login/login_screen_controller.h"
#include "ash/login/ui/lock_screen.h"
+#include "ash/login/ui/lock_window.h"
#include "ash/login/ui/login_data_dispatcher.h"
#include "ash/public/cpp/ash_pref_names.h"
#include "ash/root_window_controller.h"
#include "ash/session/session_controller.h"
+#include "ash/shelf/shelf.h"
+#include "ash/shelf/shelf_widget.h"
#include "ash/shell.h"
#include "ash/system/status_area_widget.h"
#include "base/debug/alias.h"
@@ -391,6 +394,17 @@
DataDispatcher()->SetFingerprintUnlockState(account_id, state);
}
+void LoginScreenController::SetKioskApps(
+ std::vector<mojom::KioskAppInfoPtr> kiosk_apps) {
+ Shelf::ForWindow(Shell::Get()->GetPrimaryRootWindow())
+ ->shelf_widget()
+ ->SetLoginKioskApps(std::move(kiosk_apps));
+}
+
+void LoginScreenController::LaunchKioskApp(const std::string& app_id) {
+ login_screen_client_->LaunchKioskApp(app_id);
+}
+
void LoginScreenController::DoAuthenticateUser(const AccountId& account_id,
const std::string& password,
bool authenticated_by_pin,