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

Side by Side Diff: chrome/browser/android/vr_shell/ui_scene.cc

Issue 2740143002: Change base::Value::ListStorage to std::vector<base::Value> (Closed)
Patch Set: Fix Android Compilation Error Created 3 years, 9 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/android/vr_shell/ui_scene.h" 5 #include "chrome/browser/android/vr_shell/ui_scene.h"
6 6
7 #include <string> 7 #include <string>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 animations.erase(it); 281 animations.erase(it);
282 return; 282 return;
283 } 283 }
284 } 284 }
285 } 285 }
286 286
287 void UiScene::HandleCommands(std::unique_ptr<base::ListValue> commands, 287 void UiScene::HandleCommands(std::unique_ptr<base::ListValue> commands,
288 int64_t time_in_micro) { 288 int64_t time_in_micro) {
289 for (auto& item : *commands) { 289 for (auto& item : *commands) {
290 base::DictionaryValue* dict; 290 base::DictionaryValue* dict;
291 CHECK(item->GetAsDictionary(&dict)); 291 CHECK(item.GetAsDictionary(&dict));
292 292
293 Command type; 293 Command type;
294 base::DictionaryValue* data; 294 base::DictionaryValue* data;
295 CHECK(ParseInt(*dict, "type", &type)); 295 CHECK(ParseInt(*dict, "type", &type));
296 CHECK(dict->GetDictionary("data", &data)); 296 CHECK(dict->GetDictionary("data", &data));
297 297
298 switch (type) { 298 switch (type) {
299 case Command::ADD_ELEMENT: 299 case Command::ADD_ELEMENT:
300 AddUiElementFromDict(*data); 300 AddUiElementFromDict(*data);
301 break; 301 break;
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 content_element_ = element; 489 content_element_ = element;
490 break; 490 break;
491 default: 491 default:
492 element->fill = Fill::NONE; 492 element->fill = Fill::NONE;
493 break; 493 break;
494 } 494 }
495 } 495 }
496 } 496 }
497 497
498 } // namespace vr_shell 498 } // namespace vr_shell
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698