SharpDX.Toolkit.Input
The assembly provides a high level Input API.
State of a button or key.
Initializes a new instance of the struct.
The state.
Resets the Pressed and Released events.
Indicates whether the current object is equal to another object of the same type.
An object to compare with this object.
true if the current object is equal to the parameter; otherwise, false.
Implements the ==.
The left.
The right.
The result of the operator.
Implements the !=.
The left.
The right.
The result of the operator.
Performs an implicit conversion from to .
State of the button.
The result of the conversion.
Performs an implicit conversion from to .
State of the button.
The result of the conversion.
Gets the state of this button as an enum.
The state.
Gets a value indicating whether the button is being pressed.
true if the button is being pressed; otherwise, false.
Gets a value indicating whether the button was pressed since last frame.
true if the button was pressed since last frame; otherwise, false.
Gets a value indicating whether the button was released since last frame.
true if the button was released since last frame; otherwise, false.
State of a button declared as an enum. See .
Button is in a none state.
The button is being pressed.
The button was pressed since last frame.
The button was released since last frame.
Provides access to snapshot
Returns immediate state of keyboard at the moment of call
An instance of with the information about pressed keys
Provides access to platform-independent pointer events
Gets the current state of the pointer
An instance of class
Fills the provided object with the current pointer state information
All properties of provided object will be cleared.
The object that needs to be filled with pointer information
Is thrown when is null
Provides access to keyboard state
Creates a new instance of class.
The instance whose window is used as source of keyboard input events
Is thrown if is null
Initializes this instance and starts listening to keyboard input events
Is thrown if keyboard manager is used on an unsupported platform.
Gets current keyboard state.
A snapshot of current keyboard state
Handles the event
The pressed key
Handles the event
The released key
Provides platform-specific bindings to keyboard input events
Creates a new instance of class.
The native window object reference
Is thrown when is null
Creates a platform-specific instance of class.
The native window object reference
Is thrown when is null
The instance of
Derived classes should implement platform-specific event bindings in this method
The native window object reference
Raises the event.
The key that was pressed
Raises the event.
The key that was released
Generic helper method to call a single-parameter event handler
This ensures that during the call - the handler reference will not be lost (due to stack-copy of delegate reference)
The type of event argument
The reference to event delegate
The event argument
Raised when a key down.
Raised when a key is up.
Represents the immediate state of keyboard (pressed keys)
The returned values from member methods require computation - it is advised to cache them when they needs to be reused
Checks if the specified key is being pressed
Cache the returned value if it needs to be reused
A to check whether it is pressed or not
True if the specified key is being pressed; False - otherwise
Checks if the specified key has been pressed since last frame
Cache the returned value if it needs to be reused
A to check whether it is pressed or not
True if the key is pressed; False - otherwise
Checks if the specified key has been released since last frame.
Cache the returned value if it needs to be reused
A to check whether if the specified key has been released since last frame
True if the specified key has been released since last frame; False - otherwise
Gets an array with all keys down.
The list of keys that will received keys being pressed.
keys
This method clears the list before appending
Gets the state of specified key
Cache the returned value if it needs to be reused
A to check whether it is pressed or not
The state of a key.
These flags represent the corresponding modifier keys that were pressed at some specific event.
No modifier key are pressed.
The CTRL modifier key.
The SHIFT modifier key.
The ALT modifier key.
The WIN modifier key.
Keyboard buttons
At this time only 256 key codes are supported
The namespace provides a high level Input API.
Service provides access to mouse state
Gets current mouse state.
A snapshot of current mouse state
Sets the position of mouse pointer
The desired position
Represents a mouse button
No button ('null-object' pattern)
Left mouse button
Middle mouse button
Right mouse button
Mouse X-Button 1
Mouse X-Button 2
The component provides access to mouse state
Initializes a new instance of class
The instance whose window is used as source of mouse input events
Is thrown if is null
Initializes this instance and starts listening to mouse input events
Is thrown if mouse manager is used on an unsupported platform.
Gets current mouse state.
A snapshot of current mouse state
Is thrown if is not called.
Sets the position of mouse pointer
The desired position in the range X/Y [0,1]
Is thrown when is not initialized
Updates the mouse states.
Not used.
Handler for event
The pressed button
Handler for event
The pressed button
Handler for event
The pressed button
Sets the state of specified mouse button
The button whose state needs to be set.
if set to true [is pressed].
button
Is thrown if the has an unknown value.
Computes the next state from the provided button sate.
The current button state.
A value indicating whether the button is pressed or not.
The structure represents a snapshot of mouse state.
Is immutable.
Initializes a new instance of the structure.
State of the left button
State of the middle button
State of the right button
State of the X-Button 1
State of the X-Button 2
X-position of the mouse cursor
Y-position of the mouse cursor
Delta of mouse wheel relative to previous input event
Implements the ==.
The left.
The right.
The result of the operator.
Implements the !=.
The left.
The right.
The result of the operator.
State of the left button
State of the middle button
State of the right button
State of the X-Button 1
State of the X-Button 2
X-position of the mouse cursor in the range [0,1]
Y-position of the mouse cursor in the range [0,1]
Gets the delta on x since the previous update.
The delta x.
Gets the delta y since the previous update.
The delta y.
Gets the mouse scroll wheel value since the previous update.
Represent the specific pointer device type
Touch pointer device. A touchscreen, for example.
The pen pointer device.
The mouse.
Represents the type of pointer event
The pointer capture was lost
The pointer entered the current control bounds
The pointer exited the current control bounds
The pointer moved over the current control bounds
The pointer was pressed
The pointer was released
The pointer wheel changed its state
Provides cross-platform access to pointer events
Initializes a new instance of class
The instance whose window is used as source of pointer input events
Is thrown if is null
Initializes this instance of class.
Is thrown when this functionality is not supported on current platform
Adds a pointer point to the raised events collection. It will be copied to pointer state at next update.
The raised pointer event
Raises a simple event in a thread-safe way due to stack-copy of delegate reference
The event handler that needs to be raised
Base class for platform-specific event bindings
Initializes a new instance of class
The platform-specific reference to window object
The whose events will be raised in response to platform-specific events
Is thrown when either or is null.
Creates a platform-specific instance of class.
The platform-specific reference to window object
The whose events will be raised in response to platform-specific events
Is thrown when either or is null.
Is thrown when this functionality is not supported on current platform
The platform-specific instance.
Derived classes should perform the binding to platform-specific events on and raise the corresponding events on .
The platform-specific reference to window object
WinPhone 8 platform-specific implementation of .
Implements .
Initializes a new instance of class.
The platform-specific reference to window object
The whose events will be raised in response to platform-specific events
Is thrown when either or is null.
Binds the corresponding event handler to the provided
An instance of whose events needs to be bound to
Is thrown if is null
Binds the corresponding event handler to the provided
An instance of whose events needs to be bound to
Is thrown if is null
Binds to the following events:
,
,
An instance of .
Is thrown if is null.
Creates a platform-independent instance of class from WP8-specific objects.
The pointer event type.
The WP8-specific instance of pointer point.
An instance of class.
Represents a platform-independent information about a pointer event.
Indicates whether the current object is equal to another object of the same type.
An object to compare with this object.
true if the current object is equal to the parameter; otherwise, false.
Implements the ==.
The left.
The right.
The result of the operator.
Implements the !=.
The left.
The right.
The result of the operator.
The type of event that represents current pointer point
The device type that raised the event.
An unique identifier of this pointer input point.
The location of pointer input point in client coordinates.
The timestamp when the event occurred.
The pressed key modifiers when the event occurred.
The bounding rectangle of the contact area (typically for touch).
Indicates whether the barrel button of the pen/stylus device is pressed.
Indicates whether the input was canceled by pointer device.
Indicates whether the input is from the digitizer eraser.
Indicates whether the input is from the mouse tilt wheel.
Indicates whether the finger or pen is in range of the digitizer.
Indicates whether the digitizer is inverted.
Indicates whether the input is from the left button of the mouse or other input device.
Indicates whether the input is from the middle button of the mouse or other input device.
Indicates whether the input is from the right button of the mouse or other input device.
Indicates whether the input is from the X button 1 of the mouse or other input device.
Indicates whether the input is from the X button 2 of the mouse or other input device.
Indicates whether the input is from the primary pointer when multiple pointers are registered.
Indicates the raw device value of the change in wheel button input from the last event.
Indicates the counter-clockwise angle of the pointer device around the z-axis (perpendicular to digitizer).
Indicates whether the pointer device rejected the touch input.
Indicates the clock-wise rotation of the pointer device around its own major axis.
Indicates the plane angle between the Y-Z plane and the plane that contain the Y axis and the axis of the input device (typically pen or stylus).
Indicates the plane angle between the X-Z plane and the plane that contain the X axis and the axis of the input device (typically pen or stylus).
Indicates the kind of pointer state change.
Contains collection of
Initializes a new instance of class
The collection of that were raised at some specific time
Indicates the kind of the pointer state change.
Other pointer event.
The left device button was pressed.
The left device button was released.
The right device button was pressed.
The right device button was released.
The middle device button was pressed.
The middle device button was released.
The device X-button 1 was pressed.
The device X-button 1 was released.
The device X-button 2 was pressed.
The device X-button 2 was released.
Base class for platform-specific event bindings
Initializes a new instance of class
The native window object reference
Is thrown when is null
Creates a platform-specific instance of class.
The native window object reference
Is thrown when is null
The instance of
Returns the location of mouse cursor relative to program window
Sets the mouse cursor location.
The position in space [0,1].
Supported only on Desktop platform. On other platforms the call of this method has no effect.
Derived classes should implement platform-specific event bindings in this method
The native window object reference
Derived classes should implement platform-specific code to retrieve the mouse cursor location
Raises the event
Mouse button which has been pressed
Raises the event
Mouse button which has been released
Raises the event
Current value of mouse wheel delta
Generic helper method to call a single-parameter event handler
This ensures that during the call - the handler reference will not be lost (due to stack-copy of delegate reference)
The type of event argument
The reference to event delegate
The event argument
Raised when a button is pressed
Raised when a button is released
Raised when mouse wheel delta is changed