pads: send value when setting spring to true, but only if there's a value change
This commit is contained in:
parent
faba19e94c
commit
69c52921c4
3 changed files with 7 additions and 2 deletions
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
- bug fixes
|
||||
- matrix: prevent error when `quantity` is invalid
|
||||
- multixy/xy: send value when setting `spring` to `true` (only if current value is different than spring value)
|
||||
|
||||
## 1.29.5
|
||||
|
||||
|
|
|
|||
|
|
@ -402,7 +402,7 @@ class MultiXy extends Pad {
|
|||
case 'spring':
|
||||
case 'pointSize':
|
||||
case 'axisLock':
|
||||
this.updatePadsAttr()
|
||||
this.updatePadsAttr(options)
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -281,7 +281,11 @@ module.exports = class Xy extends Pad {
|
|||
this.batchDraw()
|
||||
return
|
||||
case 'spring':
|
||||
if (this.getProp('spring') && !this.touched) this.setValue([this.faders.x.getSpringValue(),this.faders.y.getSpringValue()], {...options})
|
||||
if (this.getProp('spring') && !this.touched) {
|
||||
var x = this.faders.x.getSpringValue(),
|
||||
y = this.faders.y.getSpringValue()
|
||||
if (x !== this.value[0] || y !== this.value[1]) this.setValue([x, y], {...options})
|
||||
}
|
||||
return
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue