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

Unified Diff: chrome/browser/resources/sync_internals/sync_node_browser.js

Issue 224563004: sync: Re-implement getAllNodes WebUI function (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Many updates Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/sync_internals/sync_node_browser.js
diff --git a/chrome/browser/resources/sync_internals/sync_node_browser.js b/chrome/browser/resources/sync_internals/sync_node_browser.js
index d20b864e4ec9513c2b37d6ff042e952d2b931ac2..cbc3b0a745c6b9dad09c43fcd2e9fb62de8fd2b4 100644
--- a/chrome/browser/resources/sync_internals/sync_node_browser.js
+++ b/chrome/browser/resources/sync_internals/sync_node_browser.js
@@ -178,7 +178,12 @@
clear();
setLastRefreshTime('In progress since ' + (new Date()).toLocaleString());
- chrome.sync.getAllNodes(function(nodes) {
+ chrome.sync.getAllNodes(function(nodeMap) {
+ // Put all nodes into one big list that ignores the type.
+ var nodes = nodeMap
+ .map(function(x) { return x.nodes; })
+ .reduce(function(a, b) { return a.concat(b); });
Dan Beam 2014/04/05 00:19:25 . at end
rlarocque 2014/04/05 00:27:29 Done.
+
var treeContainer = $('sync-node-tree-container');
var tree = document.createElement('tree');
tree.setAttribute('id', 'sync-node-tree');

Powered by Google App Engine
This is Rietveld 408576698