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

Unified Diff: chrome/browser/ui/webui/ntp/app_launcher_handler.cc

Issue 399493002: Remove many instances of CreateBooleanValue. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 5 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/ntp/app_launcher_handler.cc
diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
index 8ba4e5c5c0b9239516b54ef33903c427e518658c..cd0a0d8cda98e2dad7a4288135ce313086ee66ca 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
@@ -270,13 +270,11 @@ void AppLauncherHandler::Observe(int type,
ExtensionPrefs* prefs =
ExtensionPrefs::Get(extension_service_->profile());
- scoped_ptr<base::FundamentalValue> highlight(
- base::Value::CreateBooleanValue(
- prefs->IsFromBookmark(extension->id()) &&
- attempted_bookmark_app_install_));
+ base::FundamentalValue highlight(
+ prefs->IsFromBookmark(extension->id()) &&
+ attempted_bookmark_app_install_);
attempted_bookmark_app_install_ = false;
- web_ui()->CallJavascriptFunction(
- "ntp.appAdded", *app_info, *highlight);
+ web_ui()->CallJavascriptFunction("ntp.appAdded", *app_info, highlight);
}
break;
@@ -312,12 +310,11 @@ void AppLauncherHandler::Observe(int type,
if (uninstalled)
visible_apps_.erase(extension->id());
- scoped_ptr<base::FundamentalValue> uninstall_value(
- base::Value::CreateBooleanValue(uninstalled));
- scoped_ptr<base::FundamentalValue> from_page(
- base::Value::CreateBooleanValue(!extension_id_prompting_.empty()));
web_ui()->CallJavascriptFunction(
- "ntp.appRemoved", *app_info, *uninstall_value, *from_page);
+ "ntp.appRemoved",
+ *app_info,
+ base::FundamentalValue(uninstalled),
+ base::FundamentalValue(!extension_id_prompting_.empty()));
}
break;
}

Powered by Google App Engine
This is Rietveld 408576698