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

Side by Side Diff: chrome/browser/ui/webui/options/easy_unlock_handler.cc

Issue 1995113002: Rename WebUI::CallJavascriptFunction to WebUI::CallJavascriptFunctionUnsafe (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/options/easy_unlock_handler.h" 5 #include "chrome/browser/ui/webui/options/easy_unlock_handler.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 status_string = "pending"; 83 status_string = "pending";
84 break; 84 break;
85 case EasyUnlockService::FAIL: 85 case EasyUnlockService::FAIL:
86 status_string = "server-error"; 86 status_string = "server-error";
87 break; 87 break;
88 default: 88 default:
89 LOG(ERROR) << "Unknown Easy unlock turn-off operation status: " << status; 89 LOG(ERROR) << "Unknown Easy unlock turn-off operation status: " << status;
90 status_string = "idle"; 90 status_string = "idle";
91 break; 91 break;
92 } 92 }
93 web_ui()->CallJavascriptFunction("EasyUnlockTurnOffOverlay.updateUIState", 93 web_ui()->CallJavascriptFunctionUnsafe(
94 base::StringValue(status_string)); 94 "EasyUnlockTurnOffOverlay.updateUIState",
95 base::StringValue(status_string));
95 } 96 }
96 97
97 void EasyUnlockHandler::HandleGetTurnOffFlowStatus( 98 void EasyUnlockHandler::HandleGetTurnOffFlowStatus(
98 const base::ListValue* args) { 99 const base::ListValue* args) {
99 SendTurnOffOperationStatus(); 100 SendTurnOffOperationStatus();
100 } 101 }
101 102
102 void EasyUnlockHandler::HandleRequestTurnOff(const base::ListValue* args) { 103 void EasyUnlockHandler::HandleRequestTurnOff(const base::ListValue* args) {
103 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->RunTurnOffFlow(); 104 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->RunTurnOffFlow();
104 } 105 }
105 106
106 void EasyUnlockHandler::HandlePageDismissed(const base::ListValue* args) { 107 void EasyUnlockHandler::HandlePageDismissed(const base::ListValue* args) {
107 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->ResetTurnOffFlow(); 108 EasyUnlockService::Get(Profile::FromWebUI(web_ui()))->ResetTurnOffFlow();
108 } 109 }
109 110
110 } // namespace options 111 } // namespace options
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/options/create_profile_handler.cc ('k') | chrome/browser/ui/webui/options/font_settings_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698