From 0e4395a8a3f7b5da15c46308eee9721ce3f4f475 Mon Sep 17 00:00:00 2001 From: pythongosssss <125205205+pythongosssss@users.noreply.github.com> Date: Wed, 13 Sep 2023 18:42:44 +0100 Subject: [PATCH] Allow pasting nodes with connections in firefox --- web/scripts/app.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/web/scripts/app.js b/web/scripts/app.js index 9db4e9230a3..6dd1f3edd87 100644 --- a/web/scripts/app.js +++ b/web/scripts/app.js @@ -671,6 +671,10 @@ export class ComfyApp { */ #addPasteHandler() { document.addEventListener("paste", (e) => { + // ctrl+shift+v is used to paste nodes with connections + // this is handled by litegraph + if(this.shiftDown) return; + let data = (e.clipboardData || window.clipboardData); const items = data.items; @@ -853,7 +857,7 @@ export class ComfyApp { } // Ctrl+V Paste - if ((e.key === 'v' || e.key == 'V') && (e.metaKey || e.ctrlKey)) { + if ((e.key === 'v' || e.key == 'V') && (e.metaKey || e.ctrlKey) && !e.shiftKey) { // Trigger onPaste return true; }