From 865d2f91248b0d82ef231d6ce58930caee6800a1 Mon Sep 17 00:00:00 2001 From: Nils Schneider Date: Wed, 6 Jun 2012 01:26:38 +0200 Subject: [PATCH] dead code removal --- html/force.js | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/html/force.js b/html/force.js index 2df8ffd..f8d3ba1 100644 --- a/html/force.js +++ b/html/force.js @@ -113,8 +113,6 @@ function update_graph() { update(data, value) } -var i, j - var vis = d3.select("#chart").append("svg") .attr("width", w) .attr("height", h) @@ -166,7 +164,6 @@ var data d3.json("nodes.json", function(json) { force.linkDistance(function (d) { return d.distance; }) .linkStrength(function (d) { return d.strength; }) - .start() json.links.forEach(function(d) { var node, other @@ -210,7 +207,7 @@ function update(src, type) { var link = vis.select("g.links") .selectAll("g.link") .data(links, function(d) { - return d.id || (d.id = ++j) + return d.id }) var linkEnter = link.enter().append("g") @@ -247,7 +244,7 @@ function update(src, type) { .selectAll("g.node") .data(nodes, function(d) { - return d.id || (d.id = ++i) + return d.id } ) var nodeEnter = node.enter().append("g")