initial checkin
[org.ibex.widgets.git] / src / org / ibex / theme / win2k / check.t
1 <!-- Copyleft 2004 - see COPYING for details [LGPL] -->
2
3 <ibex xmlns="org.ibex.theme.win2k">
4     <ui:box redirect="$content" align="center" padding="0 5">
5
6         action ++= function(v) { selected = !selected; }
7
8         active ++= function(v) { $bg.fill = "#d4d0c8"; }
9
10         enabled ++= function(v) {
11             $bg.fill = v ? "#ffffff" : "#d4d0c8";
12             textcolor = v ? "#000000" : "#888888";
13         }
14
15         focused ++= function(v) { cascade = v; fill = focused ? "#aaa" : null; }
16
17         var setbg = function(v) { $bg.fill = "#ffffff"; }
18         hover ++= setbg;
19         normal ++= setbg;
20
21         mixed ++= function(v) {
22             if (v) {
23                 $check.fill = .image.check_mixed;
24                 $check.visible = true;
25             }
26         }
27
28         selected ++= function(v) { cascade = v; $check.visible = selected; }
29
30         <bevel form="down" width="14" height="14">
31             <ui:box id="bg" fill="white">
32                 <ui:box id="check" fill=".image.check" shrink="true" visible="false" />
33             </ui:box>
34         </bevel>
35         <ui:box id="content" />
36     </ui:box>
37 </ibex>