diff options
| author | Alon Levy <alon@pobox.com> | 2015-03-09 16:10:13 +0200 |
|---|---|---|
| committer | Alon Levy <alon@pobox.com> | 2015-03-09 16:10:25 +0200 |
| commit | dc0b13d527871e8c7f0307bb60aa06432832e79b (patch) | |
| tree | 523567d18ae00ff72736a1c93301e8bff2d9cf0c /src | |
| parent | da6c1f39fc247715804fe346ec6e6d3a79deff4f (diff) | |
client: graph_view: update image href+width+height on every "frame"
Diffstat (limited to 'src')
| -rw-r--r-- | src/client/view/graph_view.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/client/view/graph_view.js b/src/client/view/graph_view.js index 97830889..42da39aa 100644 --- a/src/client/view/graph_view.js +++ b/src/client/view/graph_view.js @@ -435,10 +435,7 @@ function GraphView(spec) { .attr("class", "nodeurl graph") .attr("transform", "translate(10,-7)") .attr("dy", node_text_dy); - noderef.insert("image") - .attr("width", "14") - .attr("height", "14") - .attr("xlink:href", "/static/img/url-icon.png"); + noderef.insert("image"); var urlValid = function(d) { return d.url !== undefined && d.url !== null && d.url.length > 0; @@ -470,7 +467,10 @@ function GraphView(spec) { .attr("pointer-events", function(d) { return urlValid(d) ? "all" : "none"; }); node.select('g.node text') .attr("dx", nodeTextX); - + node.select('g.node a image') + .attr("width", "14") + .attr("height", "14") + .attr("xlink:href", "/static/img/url-icon.png"); circle = nodeEnter.insert("circle"); node.select('g.node circle') .attr("class", function(d) { |
