Skip to content

Mouse Class

Adds mouse-related extension methods for IScreenObject.

C#
public static class Mouse

Inheritance object

WithMouse(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>)

Section titled “WithMouse(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>)”

Adds a mouse handler to a IScreenObject.

C#
public static IScreenObject WithMouse(this IScreenObject screenObject, Func<IScreenObject, MouseScreenObjectState, bool> handler)

screenObject IScreenObject
The object to use.

handler Func<IScreenObject, MouseScreenObjectState, bool>
The handler callback.

IScreenObject

Removes all of the mouse hooks added with WithMouse(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>).

C#
public static IScreenObject RemoveMouseHooks(this IScreenObject screenObject)

screenObject IScreenObject
The object to use.

IScreenObject

RemoveMouseHook(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>)

Section titled “RemoveMouseHook(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>)”

Removes the specified handler that was added with WithMouse(IScreenObject, Func<IScreenObject, MouseScreenObjectState, bool>).

C#
public static IScreenObject RemoveMouseHook(this IScreenObject screenObject, Func<IScreenObject, MouseScreenObjectState, bool> handler)

screenObject IScreenObject
The object to use.

handler Func<IScreenObject, MouseScreenObjectState, bool>
The handler callback.

IScreenObject