Skip to content

Update Class

Adds logic extension methods for IScreenObject.

C#
public static class Update

Inheritance object

WithUpdate(IScreenObject, Action<IScreenObject, TimeSpan>)

Section titled “WithUpdate(IScreenObject, Action<IScreenObject, TimeSpan>)”

Adds a keyboard handler to a IScreenObject.

C#
public static IScreenObject WithUpdate(this IScreenObject screenObject, Action<IScreenObject, TimeSpan> handler)

screenObject IScreenObject
The object to use.

handler Action<IScreenObject, TimeSpan>
The handler callback.

IScreenObject

Removes all of the keyboard hooks added with WithUpdate(IScreenObject, Action<IScreenObject, TimeSpan>).

C#
public static IScreenObject RemoveUpdateHooks(this IScreenObject screenObject)

screenObject IScreenObject
The object to use.

IScreenObject

RemoveUpdateHook(IScreenObject, Action<IScreenObject, TimeSpan>)

Section titled “RemoveUpdateHook(IScreenObject, Action<IScreenObject, TimeSpan>)”

Removes the specified handler that was added with WithUpdate(IScreenObject, Action<IScreenObject, TimeSpan>).

C#
public static IScreenObject RemoveUpdateHook(this IScreenObject screenObject, Action<IScreenObject, TimeSpan> handler)

screenObject IScreenObject
The object to use.

handler Action<IScreenObject, TimeSpan>
The handler callback.

IScreenObject