Calling cancel()
unschedules the current timer, ensuring it does not fire again until re-scheduled using Timer.scheduleOnce()
or Timer.scheduleRepeat()
.
This function has no parameters.
None (undefined
).
// A one shot timer:
> timer = new Timer"Fired!";
undefined
> 20;
undefined
> ;
undefined
// did not fire!
// A repeating timer:
> timer2 = new Timer"Repeat fire!";
undefined
> 0 1;
undefined
Repeat fire!
Repeat fire!
Repeat fire!
>
undefined
XPLMScheduleFlightLoop
to unschedule the timer.stop_timer()