value events: remove some useless flags
This commit is contained in:
parent
93d3b159ca
commit
c3002b99c3
2 changed files with 4 additions and 4 deletions
|
|
@ -65,7 +65,7 @@ var StateManager = class StateManager {
|
|||
|
||||
if (widgets[j].setValue && !widgets[j].noValueState) {
|
||||
|
||||
widgets[j].setValue(value, {send:send, sync:true, fromState:true})
|
||||
widgets[j].setValue(value, {send:send, sync:true})
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -226,7 +226,7 @@ var StateManager = class StateManager {
|
|||
if (this.valueStateQueue[id] !== undefined) {
|
||||
for (let w of widgetManager.getWidgetById(id)) {
|
||||
if (w.noValueState) continue
|
||||
w.setValue(this.valueStateQueue[id], {sync: true, fromState:true, fromEdit: true})
|
||||
w.setValue(this.valueStateQueue[id], {sync: true, script: false})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -235,7 +235,7 @@ var StateManager = class StateManager {
|
|||
if (this.valueNewPropQueue[id] != this.valueOldPropQueue[id]) {
|
||||
for (let w of widgetManager.getWidgetById(id)) {
|
||||
if (w.noValueState) continue
|
||||
w.setValue(w.getProp('value'), {sync: true, fromState:true})
|
||||
w.setValue(w.getProp('value'), {sync: true})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ class Widget extends EventEmitter {
|
|||
context: {value: 0, id: '', touch: undefined}
|
||||
})
|
||||
this.on('value-changed', (e)=>{
|
||||
if (e.widget === this && this.mounted && !e.options.fromEdit && e.options.script !== false) {
|
||||
if (e.widget === this && this.mounted && e.options.script !== false) {
|
||||
this.scripts.onValue.run({
|
||||
value: e.options.widget ? e.options.widget.value : this.value,
|
||||
id: e.options.id || e.id
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue