Here is a possible approach:
var w = new Window('dialog'),
g = w.add('group')
g1 = g.add('group'),
g2 = g.add('group'),
btn = w.add('button', undefined, "Cancel"),
cb, dd;
for ( i = 0; i < 5; i++ ) {
cb = g1.add('checkbox',undefined,(i+1));
cb.index = i;
cb.alignment = "fill";
dd = g2.add('dropdownlist',undefined,(i+1));
dd.enabled = false;
dd.alignment = "fill";
}
g1.addEventListener ('mousedown', function(evt){
var cb = evt.target, index, n = g1.children.length, cb, dd, value;
if(cb.constructor.name != "Checkbox") return;
index = cb.index;
value = !cb.value;
while ( n-- ) {
dd = g2.children;
cb = g1.children;
dd.enabled = !value? false : ( n == index );
value && n != index && cb.value = false;
}
});
g1.children[0].value = true;
g2.children[0].enabled = true;
g1.orientation = g2.orientation = "column";
g.orientation = "row";
w.show();
Although I would process differently myself using constructors and somme event programming:
Event-Driven Programming with ExtendScript | Ozalto
HTH