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

Unified Diff: chrome/browser/ui/webui/options/import_data_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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/options/import_data_handler.cc
diff --git a/chrome/browser/ui/webui/options/import_data_handler.cc b/chrome/browser/ui/webui/options/import_data_handler.cc
index 17732049caa8824ffdc54313e1064ec8444c288c..72127cea65c6963ab9297ce6b101407511f6f307 100644
--- a/chrome/browser/ui/webui/options/import_data_handler.cc
+++ b/chrome/browser/ui/webui/options/import_data_handler.cc
@@ -112,8 +112,8 @@ void ImportDataHandler::StartImport(
importer_host_->set_observer(NULL);
base::FundamentalValue importing(true);
- web_ui()->CallJavascriptFunction("ImportDataOverlay.setImportingState",
- importing);
+ web_ui()->CallJavascriptFunctionUnsafe("ImportDataOverlay.setImportingState",
+ importing);
import_did_succeed_ = false;
importer_host_ = new ExternalProcessImporterHost();
@@ -195,8 +195,8 @@ void ImportDataHandler::InitializePage() {
browser_profiles.Append(browser_profile);
}
- web_ui()->CallJavascriptFunction("ImportDataOverlay.updateSupportedBrowsers",
- browser_profiles);
+ web_ui()->CallJavascriptFunctionUnsafe(
+ "ImportDataOverlay.updateSupportedBrowsers", browser_profiles);
}
void ImportDataHandler::ImportStarted() {
@@ -223,12 +223,12 @@ void ImportDataHandler::ImportEnded() {
importer_host_ = NULL;
if (import_did_succeed_) {
- web_ui()->CallJavascriptFunction("ImportDataOverlay.confirmSuccess");
+ web_ui()->CallJavascriptFunctionUnsafe("ImportDataOverlay.confirmSuccess");
} else {
base::FundamentalValue state(false);
- web_ui()->CallJavascriptFunction("ImportDataOverlay.setImportingState",
- state);
- web_ui()->CallJavascriptFunction("ImportDataOverlay.dismiss");
+ web_ui()->CallJavascriptFunctionUnsafe(
+ "ImportDataOverlay.setImportingState", state);
+ web_ui()->CallJavascriptFunctionUnsafe("ImportDataOverlay.dismiss");
}
}

Powered by Google App Engine
This is Rietveld 408576698