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

Unified Diff: chrome/browser/ui/webui/settings/reset_settings_handler.cc

Issue 1988463002: MD Settings: Convert C++ handlers to be JavaScript-lifecycle aware. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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/settings/reset_settings_handler.cc
diff --git a/chrome/browser/ui/webui/settings/reset_settings_handler.cc b/chrome/browser/ui/webui/settings/reset_settings_handler.cc
index f028f3b3d62bc1c668efdcec8ffed5a3abe53bd8..263895cf5ea88e77a31abd4b0edbf9cb27ab3363 100644
--- a/chrome/browser/ui/webui/settings/reset_settings_handler.cc
+++ b/chrome/browser/ui/webui/settings/reset_settings_handler.cc
@@ -114,6 +114,8 @@ void ResetSettingsHandler::RegisterMessages() {
void ResetSettingsHandler::HandleResetProfileSettings(
const base::ListValue* args) {
+ AllowJavascript();
+
CHECK_EQ(2U, args->GetSize());
std::string callback_id;
CHECK(args->GetString(0, &callback_id));
@@ -153,6 +155,8 @@ void ResetSettingsHandler::OnResetProfileSettingsDone(
void ResetSettingsHandler::HandleGetReportedSettings(
const base::ListValue* args) {
+ AllowJavascript();
+
CHECK_EQ(1U, args->GetSize());
std::string callback_id;
CHECK(args->GetString(0, &callback_id));
« no previous file with comments | « chrome/browser/ui/webui/settings/reset_settings_handler.h ('k') | chrome/browser/ui/webui/settings/search_engines_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698