mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-02 12:11:58 +00:00
[BugFix] Trigger IWidget.callback on widget drag (#514)
This commit is contained in:
@@ -119,6 +119,7 @@ export class SliderWidget extends BaseWidget implements ISliderWidget {
|
||||
override onDrag(options: {
|
||||
e: CanvasMouseEvent
|
||||
node: LGraphNode
|
||||
canvas: LGraphCanvas
|
||||
}) {
|
||||
if (this.options.read_only) return false
|
||||
|
||||
@@ -131,9 +132,7 @@ export class SliderWidget extends BaseWidget implements ISliderWidget {
|
||||
const newValue = this.options.min + (this.options.max - this.options.min) * slideFactor
|
||||
|
||||
if (newValue !== this.value) {
|
||||
this.value = newValue
|
||||
return true
|
||||
this.setValue(newValue, options)
|
||||
}
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user