Manage app.ts litegraph keybindings (#1151)

* Manage app.ts litegraph keybindings

* nit
This commit is contained in:
Chenlei Hu
2024-10-07 16:50:58 -04:00
committed by GitHub
parent ff1ca268a4
commit cc17bee945
6 changed files with 159 additions and 77 deletions

View File

@@ -30,7 +30,7 @@ app.registerExtension({
const keybindingStore = useKeybindingStore()
const commandStore = useCommandStore()
const keybinding = keybindingStore.getKeybinding(keyCombo)
if (keybinding) {
if (keybinding && keybinding.targetSelector !== '#graph-canvas') {
await commandStore.execute(keybinding.commandId)
event.preventDefault()
return