1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Don't allow virtual links to be spliced

Fixes #1920
This commit is contained in:
Nick O'Leary 2018-10-07 11:55:43 +01:00
parent 98c1bc276d
commit cf32a33984
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
2 changed files with 3 additions and 1 deletions

View File

@ -275,7 +275,8 @@ RED.palette = (function() {
} }
for (var i=0;i<nodes.length;i++) { for (var i=0;i<nodes.length;i++) {
if (d3.select(nodes[i]).classed('link_background')) { var node = d3.select(nodes[i]);
if (node.classed('link_background') && !node.classed('link_link')) {
var length = nodes[i].getTotalLength(); var length = nodes[i].getTotalLength();
for (var j=0;j<length;j+=10) { for (var j=0;j<length;j+=10) {
var p = nodes[i].getPointAtLength(j); var p = nodes[i].getPointAtLength(j);

View File

@ -2415,6 +2415,7 @@ RED.view = (function() {
var l = d3.select(this); var l = d3.select(this);
d.added = true; d.added = true;
l.append("svg:path").attr("class","link_background link_path") l.append("svg:path").attr("class","link_background link_path")
.classed("link_link", function(d) { return d.link })
.on("mousedown",function(d) { .on("mousedown",function(d) {
mousedown_link = d; mousedown_link = d;
clearSelection(); clearSelection();