Edytuj

Udostępnij za pośrednictwem


CADisplayLink.AddToRunLoop Method

Definition

Overloads

AddToRunLoop(NSRunLoop, NSRunLoopMode)

Trigger timer events on the specified runloop for the specified modes.

AddToRunLoop(NSRunLoop, NSString)

Trigger timer events on the specified runloop for the specified modes (weakly typed parameters).

Trigger timer events on the specified runloop for the specified modes.

public void AddToRunLoop (Foundation.NSRunLoop runloop, Foundation.NSRunLoopMode mode);
member this.AddToRunLoop : Foundation.NSRunLoop * Foundation.NSRunLoopMode -> unit

Parameters

runloop
NSRunLoop

The runloop on which to run.

mode
NSRunLoopMode

Modes in which the timer will be invoked.

Remarks

The mode parameter will determine when the event is sent. The NSRunLoop.NSDefaultRunLoopMode is not delivered during UI tracking events (like scrolling in a UIScrollbar). For getting those kinds of events use NSRunLoop.UITrackingRunLoopMode. Or use NSRunLoop.NSRunLoopCommonModes which covers both cases.

Applies to

Trigger timer events on the specified runloop for the specified modes (weakly typed parameters).

[Foundation.Export("addToRunLoop:forMode:")]
public virtual void AddToRunLoop (Foundation.NSRunLoop runloop, Foundation.NSString mode);
abstract member AddToRunLoop : Foundation.NSRunLoop * Foundation.NSString -> unit
override this.AddToRunLoop : Foundation.NSRunLoop * Foundation.NSString -> unit

Parameters

runloop
NSRunLoop

The runloop on which to run.

mode
NSString

Modes in which the timer will be invoked, one of the various NSString constants in NSRunLoop.

This parameter can be null.

Attributes

Remarks

You should use the strongly typed version if possible, as it prevents common errors.

The mode parameter will determine when the event is sent. The NSRunLoop.NSDefaultRunLoopMode is not delivered during UI tracking events (like scrolling in a UIScrollbar). For getting those kinds of events use NSRunLoop.UITrackingRunLoopMode. Or use NSRunLoop.NSRunLoopCommonModes which covers both cases.

Applies to