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

Prevent accidental edit of nodes

Part of #217
This commit is contained in:
Nick O'Leary 2014-05-06 10:14:18 +01:00
parent baaf8167d3
commit d982d02810

View File

@ -695,8 +695,9 @@ RED.view = function() {
} }
function nodeMouseUp(d) { function nodeMouseUp(d) {
if (clickElapsed > 0 && clickElapsed < 300) { if (mousedown_node == d && clickElapsed > 0 && clickElapsed < 300) {
RED.editor.edit(d); RED.editor.edit(d);
clickElapsed = 0;
return; return;
} }
portMouseUp(d, d._def.inputs > 0 ? 1 : 0, 0); portMouseUp(d, d._def.inputs > 0 ? 1 : 0, 0);