Does anyone know how the rollout.controls property works? The help file says it'll return an array of all the controls in the rollout but I can't get it to recognize any of my rollouts.
In this code I'd like to collect all the controls in the rollout called eyeLidL but every time I try something like print eyeLidL.controls to access the property of the rollout it tells me that .controls is an unknown property of "undefined". But I thought eyeLidL was defined by rollout:eyeLidL? What gives?
Can anyone give me an example of how to use this property and how to get access to the rollout?
Here's my code just for reference:
attributes LeftEye
(
function ModifyOtherSpinners my_index val old_values spinners checks =
(
diff = val-old_values[my_index]
for i = 1 to old_values.count do
(
if i != my_index do
(
if checks[i].checked do spinners[i].value = spinners[i].value + diff
)
)
old_values[my_index] = val
)
parameters eyeLidL rollout:eyeLidL
(
topLid_test3 type:#float UI:topLidSp_test3
topLid_test4 type:#float UI:topLidSp_test4
compress_test1 type:#float UI:compressSp_test1
)
rollout eyeLidL "Left Eye Lids"
(
checkbutton topLidCh3 "" highlightColor:[255,217,7] height:16 width:16 align:#left offset:[-14,0] across:3
spinner topLidSp_test3 "" range:[-1,1,0] scale:0.1 align:#left offset:[-45,0] fieldWidth:30
label label1a "Top Open Close" align:#left offset:[-47,0]
checkbutton topLidCh4 "" highlightColor:[255,217,7] height:16 width:16 align:#left offset:[-14,-5] across:3
spinner topLidSp_test4 "" range:[-1,1,0] scale:0.1 align:#left offset:[-45,-5] fieldWidth:30 across:2
label label2a "Bottom Open Close" align:#left offset:[-47,-5]
checkbutton topLidCh5 "" highlightColor:[255,217,7] height:16 width:16 align:#left offset:[-14,-5] across:3
spinner compressSp_test1 "" range:[-1,1,0] scale:0.1 align:#left offset:[-45,-5] fieldWidth:30 height:30 across:2
label label3a "Compress" align:#left offset:[-47,-5]
local old_values = #( 0.0, 0.0, 0.0 )
local spinners = #( topLidSp_test3, topLidSp_test4, compressSp_test1 )
local checks = #( topLidCh3, topLidCh4, topLidCh5 )
on topLidSp_test3 changed val do ModifyOtherSpinners 1 val old_values spinners checks
on topLidSp_test4 changed val do ModifyOtherSpinners 2 val old_values spinners checks
on compressSp_test1 changed val do ModifyOtherSpinners 3 val old_values spinners checks
)
)
Thanks for any help. I've been struggling with this all week!
Anubis · 2009-12-25