pub struct DisplayLink(_);
Expand description

DisplayLink is a timer object used to synchronize drawing with the refresh rate of the display.

Implementations§

Creates a new DisplayLink with a callback that will be invoked with the Instant the screen will next refresh.

The returned DisplayLink will be in a paused state. Returns None if a DisplayLink could not be created.

Panic

If the callback panics, the process will be aborted.

Returns true if the DisplayLink is currently paused.

Pauses the DisplayLink.

A paused DisplayLink will not invoke it’s callback. On iOS, it is necessary to pause the DisplayLink in response to events like backgrounding.

Resumes the DisplayLink.

Trait Implementations§

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.