Bypass selected nodes (#2013)

Co-authored-by: filtered <176114999+webfiltered@users.noreply.github.com>
This commit is contained in:
shinich39
2024-12-23 06:51:28 +09:00
committed by GitHub
parent cce5ade578
commit f4c523f188

View File

@@ -590,9 +590,13 @@ export class ComfyApp {
options.push({
content: 'Bypass',
callback: (obj) => {
if (this.mode === LGraphEventMode.BYPASS)
this.mode = LGraphEventMode.ALWAYS
else this.mode = LGraphEventMode.BYPASS
const mode =
this.mode === LGraphEventMode.BYPASS
? LGraphEventMode.ALWAYS
: LGraphEventMode.BYPASS
for (const item of app.canvas.selectedItems) {
if (item instanceof LGraphNode) item.mode = mode
}
this.graph.change()
}
})