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

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/kiosk_app_menu_handler.cc

Issue 2664753002: Remove base::StringValue (Closed)
Patch Set: Rebase Created 3 years, 9 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/ui/webui/chromeos/login/kiosk_app_menu_handler.h" 5 #include "chrome/browser/ui/webui/chromeos/login/kiosk_app_menu_handler.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 const base::ListValue* args) { 173 const base::ListValue* args) {
174 KioskAppLaunchError::Error error = KioskAppLaunchError::Get(); 174 KioskAppLaunchError::Error error = KioskAppLaunchError::Get();
175 if (error == KioskAppLaunchError::NONE) 175 if (error == KioskAppLaunchError::NONE)
176 return; 176 return;
177 KioskAppLaunchError::RecordMetricAndClear(); 177 KioskAppLaunchError::RecordMetricAndClear();
178 178
179 const std::string error_message = KioskAppLaunchError::GetErrorMessage(error); 179 const std::string error_message = KioskAppLaunchError::GetErrorMessage(error);
180 bool new_kiosk_ui = EnableNewKioskUI(); 180 bool new_kiosk_ui = EnableNewKioskUI();
181 web_ui()->CallJavascriptFunctionUnsafe( 181 web_ui()->CallJavascriptFunctionUnsafe(
182 new_kiosk_ui ? kKioskShowErrorNewAPI : kKioskShowErrorOldAPI, 182 new_kiosk_ui ? kKioskShowErrorNewAPI : kKioskShowErrorOldAPI,
183 base::StringValue(error_message)); 183 base::Value(error_message));
184 } 184 }
185 185
186 void KioskAppMenuHandler::OnKioskAppsSettingsChanged() { 186 void KioskAppMenuHandler::OnKioskAppsSettingsChanged() {
187 SendKioskApps(); 187 SendKioskApps();
188 } 188 }
189 189
190 void KioskAppMenuHandler::OnKioskAppDataChanged(const std::string& app_id) { 190 void KioskAppMenuHandler::OnKioskAppDataChanged(const std::string& app_id) {
191 SendKioskApps(); 191 SendKioskApps();
192 } 192 }
193 193
194 void KioskAppMenuHandler::OnKioskAppDataLoadFailure(const std::string& app_id) { 194 void KioskAppMenuHandler::OnKioskAppDataLoadFailure(const std::string& app_id) {
195 SendKioskApps(); 195 SendKioskApps();
196 } 196 }
197 197
198 void KioskAppMenuHandler::UpdateState(NetworkError::ErrorReason reason) { 198 void KioskAppMenuHandler::UpdateState(NetworkError::ErrorReason reason) {
199 if (network_state_informer_->state() == NetworkStateInformer::ONLINE) 199 if (network_state_informer_->state() == NetworkStateInformer::ONLINE)
200 KioskAppManager::Get()->RetryFailedAppDataFetch(); 200 KioskAppManager::Get()->RetryFailedAppDataFetch();
201 } 201 }
202 202
203 void KioskAppMenuHandler::OnArcKioskAppsChanged() { 203 void KioskAppMenuHandler::OnArcKioskAppsChanged() {
204 SendKioskApps(); 204 SendKioskApps();
205 } 205 }
206 206
207 } // namespace chromeos 207 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc ('k') | chrome/browser/ui/webui/chromeos/login/network_dropdown.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698