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

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

Issue 2823073003: Make Use of Value::GetList API
Patch Set: Further Usages Created 3 years, 8 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 b6b522a6821c98ef927d673b6188e436f06f977a..19ca09efb229d7d27b6a8edd1058a740492a37e4 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
@@ -636,12 +636,10 @@ void AppLauncherHandler::HandleShowAppInfo(const base::ListValue* args) {
}
void AppLauncherHandler::HandleReorderApps(const base::ListValue* args) {
- CHECK(args->GetSize() == 2);
-
- std::string dragged_app_id;
- const base::ListValue* app_order;
- CHECK(args->GetString(0, &dragged_app_id));
- CHECK(args->GetList(1, &app_order));
+ CHECK(args->base::Value::GetList().size() == 2);
+ std::string dragged_app_id = args->base::Value::GetList()[0].GetString();
+ const base::ListValue* app_order =
+ static_cast<const base::ListValue*>(&args->base::Value::GetList()[1]);
std::string predecessor_to_moved_ext;
std::string successor_to_moved_ext;

Powered by Google App Engine
This is Rietveld 408576698