kasemir / org.csstudio.display.builder

Update of org.csstudio.opibuilder.*
Eclipse Public License 1.0
2 stars 10 forks source link

Script in a rule for setting the widget enable property does set the else case properly. #488

Closed tauferg closed 5 years ago

tauferg commented 5 years ago

In generating a rule to set the enable state of a widget, in this instance based upon the pvInt value of another widget, sets both the conditional (if) and non-conditional (else) states of the enable property to "true" rather than "true" and "false".

Steps:

image

kasemir commented 5 years ago

That's by design. The "else" case is always the default state, i.e. what you set on the property.

Create a new widget, it's "enabled" property is true. Create a rule for "enabled", it will always end with "else: .. enabled = true".

You can either

a) Set the enabled property to false, and then in your rule add conditions to make it true.

b) Keep enabled at the default true, but in your rule add settings that make it false.

kasemir commented 5 years ago

Closing this because it's not a bug but exactly as it's meant to be.