mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 03:01:54 +00:00
Early return in LGraphCanvas.deselectAll (#856)
Avoid trigger `onSelectionChange` when nothing is selected.
This commit is contained in:
@@ -3436,6 +3436,8 @@ export class LGraphCanvas implements ConnectionColorContext {
|
|||||||
if (!this.graph) return
|
if (!this.graph) return
|
||||||
|
|
||||||
const selected = this.selectedItems
|
const selected = this.selectedItems
|
||||||
|
if (!selected.size) return
|
||||||
|
|
||||||
let wasSelected: Positionable | undefined
|
let wasSelected: Positionable | undefined
|
||||||
for (const sel of selected) {
|
for (const sel of selected) {
|
||||||
if (sel === keepSelected) {
|
if (sel === keepSelected) {
|
||||||
|
|||||||
Reference in New Issue
Block a user