mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
[groups] Include group counts in copy/paste notifications
This commit is contained in:
@@ -2073,7 +2073,11 @@ if (DEBUG_EVENTS) { console.warn("clearSelection", mouse_mode); }
|
||||
}
|
||||
}
|
||||
clipboard = JSON.stringify(nns);
|
||||
RED.notify(RED._("clipboard.nodeCopied",{count:nns.length}),{id:"clipboard"});
|
||||
if (nodeCount > 0) {
|
||||
RED.notify(RED._("clipboard.nodeCopied",{count:nodeCount}),{id:"clipboard"});
|
||||
} else if (groupCount > 0) {
|
||||
RED.notify(RED._("clipboard.groupCopied",{count:groupCount}),{id:"clipboard"});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4307,12 +4311,16 @@ if (DEBUG_EVENTS) { console.warn("nodeMouseDown", mouse_mode,d); }
|
||||
newConfigNodeCount++;
|
||||
}
|
||||
})
|
||||
var newGroupCount = new_groups.length;
|
||||
if (new_workspaces.length > 0) {
|
||||
counts.push(RED._("clipboard.flow",{count:new_workspaces.length}));
|
||||
}
|
||||
if (newNodeCount > 0) {
|
||||
counts.push(RED._("clipboard.node",{count:newNodeCount}));
|
||||
}
|
||||
if (newGroupCount > 0) {
|
||||
counts.push(RED._("clipboard.group",{count:newGroupCount}));
|
||||
}
|
||||
if (newConfigNodeCount > 0) {
|
||||
counts.push(RED._("clipboard.configNode",{count:newNodeCount}));
|
||||
}
|
||||
|
Reference in New Issue
Block a user