clock-test.lzx
<canvas>
<include href="clock.lzx"/>
<clock id="clk" x="100" y="100" oninit="this.setCurrentTime()"/>
<button name="hour" x="400" y="100" text="h" onclick="clk.updateHands( Math.max( 1,(clk.lasthour + 3)%13), clk.lastminute, clk.lastsecond)"/>
<button name="min" x="440" y="100" text="m" onclick="clk.updateHands( clk.lasthour, Math.max( 1, (clk.lastminute + 10)%61), clk.lastsecond)"/>
<button name="sec" x="460" y="100" text="s" onclick="clk.updateHands( clk.lasthour, clk.lastminute, Math.max(1, (clk.lastsecond + 20)%61) )"/>
</canvas>
Cross References
Includes
Named Instances
- <clock id="clk">
- <button name="hour">
- <button name="min">
- <button name="sec">