client sync: use raw target to avoid comparison errors
This commit is contained in:
parent
92339a9086
commit
d64452af99
3 changed files with 13 additions and 3 deletions
|
|
@ -2,8 +2,12 @@
|
|||
|
||||
## 0.49.0
|
||||
|
||||
- **deprecation** MathJS syntax is deprecated and will be removed in the future in favor of the Javascript syntax
|
||||
**Deprecation**
|
||||
MathJS syntax is now deprecated and will be removed in the future, sessions using it will be working for a few more versions but users are strongly encouraged to migrate to the javascript syntax.
|
||||
|
||||
|
||||
- bug fixes:
|
||||
- multiclient sync not working when `targets` is empty
|
||||
- widgets: missing `target` property for `plots/*` widgets, required for MIDI bindings
|
||||
- editor: set `label` to `auto` instead of `true` when using the toggle button
|
||||
- editor: errors when hitting `mod + a` and unselecting widgets
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ var Osc = class Osc extends EventEmitter {
|
|||
let widgetTarget = widgets[i].getProp('target'),
|
||||
match = true
|
||||
|
||||
if (data.target) {
|
||||
if (data._rawTarget) {
|
||||
// if the message target is provided (when message comes from another client connected to the same server)
|
||||
// then we only update the widgets that have the exact same target
|
||||
match = deepEqual(widgetTarget, data.target)
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ module.exports = {
|
|||
|
||||
ipc.send('sessionList', recentSessions, clientId)
|
||||
ipc.send('serverTargets', settings.read('targets'), clientId)
|
||||
|
||||
|
||||
},
|
||||
|
||||
sessionAddToHistory: function(data) {
|
||||
|
|
@ -269,6 +269,9 @@ module.exports = {
|
|||
data[k] = shortdata[k]
|
||||
}
|
||||
|
||||
// only rawTarget will be used
|
||||
delete data.target
|
||||
|
||||
data.args = data.preArgs ? data.preArgs.concat(value) : [value]
|
||||
|
||||
if (!data.noSync) ipc.send('receiveOsc', data, null, clientId)
|
||||
|
|
@ -358,6 +361,9 @@ module.exports = {
|
|||
}
|
||||
}
|
||||
|
||||
// store raw target for client sync widget matching
|
||||
cache._rawTarget = widgetData.target
|
||||
|
||||
},
|
||||
|
||||
removeWidget(data, clientId) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue