Dependancies between renderlets, the clean way

Permalink to this snippet:

The authors comment: This illustrates the concept of dependancy between renderlets in Formidable.
Renderlets can be declared as dependant of others using dependsOn='rdtname'.
Dependant renderlets can be hidden if the renderlet they depend on is empty using hideIdDependancyEmpty='true'.

Every kind of renderlet may be declared as dependant of another.

The ad-hock repaint is handled via ajax; note the usage of syncValue='true' on the event to automate the refreshing of the value of the current rdt in the ajax context every time onchange is triggered.

For a working example, have a look here:

Jérôme Schneider, 2010-01-19@10:06:24, pasted: