overte/examples/timer.js

6 lines
202 B
JavaScript
Raw Normal View History

2014-01-31 16:40:24 -08:00
var timer = new Timer();
timer.interval = 1000;
timer.singleShot = true; // set this is you only want the timer to fire once
timer.timeout.connect(function() { print("TIMER FIRED!"); });
timer.start();