<class name="two_buttons" extends="view">
<button name="minimizeBtn" height="100%" width="20"> _
<attribute name="isMax" value="true"/>
<method event="onclick">
if (this.isMax) {parent.max.remove(); parent.min.apply();}
else {parent.max.apply(); parent.min.remove();}
this.isMax = !this.isMax;
</method>
</button>
<button name="closeBtn" height="100%" width="20" > X
<attribute name="isClosed" value="false"/>
<method event="onclick">
this.parent.setAttribute("visible", false);
</method>
</button>
</class>
<class name="fos_window" extends="window">
<attribute name="width" value="400" />
<attribute name="height" value="300" />
<state name="max" apply="true">
<animatorgroup duration="1000" process="simultaneous">
<animator attribute="width" to="400"/>
<animator attribute="height" to="300"/>
<animator attribute="x" to="100"/>
<animator attribute="y" to="100"/>
</animatorgroup>
<text align="center" y="20%">M a x i m i z e d</text>
</state>
<state name="min" >
<animatorgroup duration="1000" process="simultaneous">
<animator attribute="width" to="170"/>
<animator attribute="height" to="100"/>
<animator attribute="x" to="0"/>
<animator attribute="y" to="0"/>
</animatorgroup>
<text align="center" valign="middle">Minimized</text>
</state>
<two_buttons placement="title_area" align="right"/>
</class>
<fos_window title="instance title"/>
</canvas>
_______________________________________________ Laszlo-user mailing list [email protected] http://www.openlaszlo.org/mailman/listinfo/laszlo-user
