Checklist: <and> multiple entries in <condition>
Previously a <condition> block was assumed to contain a single child, and other children were ignored, largely due to the PUI code. Most developers would expect multiple children to be evaluated as if surrounded by an <and> block, which is how the tutorial code behaves. This change wraps the children in an <and> making it consistent.
This commit is contained in:
parent
78f72a5ec3
commit
2fdb17a214
1 changed files with 2 additions and 2 deletions
|
@ -210,7 +210,7 @@
|
|||
var condition = item.getNode("condition");
|
||||
|
||||
if (condition != nil) {
|
||||
var vis = t.getNode("visible", 1);
|
||||
var vis = t.getNode("visible", 1).getNode("and", 1);
|
||||
props.copy(condition, vis);
|
||||
var c = t.getNode("color", 1);
|
||||
c.getNode("red", 1).setValue(0.2);
|
||||
|
@ -242,7 +242,7 @@
|
|||
c.getNode("green", 1).setValue(0.7);
|
||||
c.getNode("blue", 1).setValue(0.2);
|
||||
|
||||
vis = t.getNode("visible", 1).getNode("not", 1);
|
||||
vis = t.getNode("visible", 1).getNode("not", 1).getNode("and", 1);
|
||||
props.copy(condition, vis);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue