mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
8 lines
413 B
TypeScript
8 lines
413 B
TypeScript
/**
|
|
* iOS specific global functions implementation.
|
|
*/
|
|
export function setTimeout(callback: Function, milliseconds: number): void {
|
|
var target = Foundation.NSObject.extends({ tick: function (timer) { callback(); } }, { exposedMethods: { "tick:": "v@:@" } });
|
|
Foundation.NSTimer.scheduledTimerWithTimeIntervalTargetSelectorUserInfoRepeats(milliseconds / 1000, new target(), "tick:", null, false);
|
|
}
|