Fix ctrl-click on wire whilst already in quick-join

This commit is contained in:
Nick O'Leary 2019-08-14 09:50:34 +01:00
parent 17d3a5840d
commit 426fd499ce
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 83 additions and 84 deletions

View File

@ -841,7 +841,6 @@ RED.view = (function() {
if (showLabel !== undefined && !/^link (in|out)$/.test(nn._def.type) && !nn._def.defaults.hasOwnProperty("l")) {
nn.l = showLabel;
}
if (!spliceLink) {
if (quickAddLink) {
var drag_line = quickAddLink;
var src = null,dst,src_port;
@ -944,7 +943,7 @@ RED.view = (function() {
}
}
}
} else {
if (spliceLink) {
resetMouseVars();
// TODO: DRY - droppable/nodeMouseDown/canvasMouseUp/showQuickAddDialog
RED.nodes.removeLink(spliceLink);
@ -960,7 +959,7 @@ RED.view = (function() {
};
RED.nodes.addLink(link1);
RED.nodes.addLink(link2);
historyEvent.links = [link1,link2];
historyEvent.links = (historyEvent.links || []).concat([link1,link2]);
historyEvent.removedLinks = [spliceLink];
}
RED.history.push(historyEvent);