I object to the proposed change. (Reasons below.)
* Sébastien MARQUE -- 2/21/2009 2:39 AM:
> In this script you'll find several listeners linked to several
> properties that can be modified using instrument-failures.xml or
> system-failures.xml.
Except that these are *not* change-only listeners.
| setlistener(f ~ "/serviceable", failure[f]);
You should have used:
setlistener(f ~ "/serviceable", failure[f], 0, 1);
... as described on the wiki page about Nasal.
But there are two other ways to avoid your problem:
- Use <live> on the checkbox and don't apply the whole dialog
every time.
- Use dialog-apply on selected checkboxes (object-name!):
<binding>
<command>dialog-apply</command>
<object-name>checkbox1</object-name>
</binding>
Because (default Nasal-)listeners are *by design* triggered whenever
they are written to, and this can be desired behavior (what about
applying a signal property multiple times?), and because there are
three methods to avoid problems arising from that, I don't think
applying the patch would be a good idea.
m.
------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Flightgear-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/flightgear-devel