Class InputGenerator
Definition
- Namespace:
- ElmSharp
- Assembly:
- ElmSharp.dll
InputGenerator provides functions to initialize/deinitialize input devices and to generation touch / key events.
public class InputGenerator : IDisposable
- Inheritance
-
objectInputGenerator
- Implements
-
System.IDisposable
Remarks
This is not for use by third-party applications.
Constructors
View SourceInputGenerator(InputDeviceType, string)
Creates and initializes a new instance of the InputGenerator class with given name.
Declaration
public InputGenerator(InputDeviceType deviceType, string name)
Parameters
Type | Name | Description |
---|---|---|
InputDeviceType | deviceType | The device type want to generate events |
string | name | The device name (maximum 31 characters) |
Remarks
This is not for use by third-party applications.
InputGenerator(InputDeviceType)
Creates and initializes a new instance of the InputGenerator class.
Declaration
public InputGenerator(InputDeviceType deviceType)
Parameters
Type | Name | Description |
---|---|---|
InputDeviceType | deviceType | The device type want to generate events |
Remarks
This is not for use by third-party applications.
Methods
View SourceDispose()
Destroys the current object.
Declaration
public void Dispose()
Remarks
This is not for use by third-party applications.
Dispose(bool)
Releases all the resources currently used by this instance.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing | true if the managed resources should be disposed, otherwise false. |
Remarks
This is not for use by third-party applications.
~InputGenerator()
Destroys the InputGenerator object.
Declaration
protected ~InputGenerator()
Remarks
This is not for use by third-party applications.
GenerateKeyEvent(string, int)
Generates all of key events using a opened device.
Declaration
public void GenerateKeyEvent(string key, int pressed)
Parameters
Type | Name | Description |
---|---|---|
string | key | The key name want to generate. |
int | pressed | The value that select key press or release. (0: release, 1: press) |
Remarks
This is not for use by third-party applications.
GenerateMouseEvent(int, InputPointerType, int, int)
Generate a pointer event using a opened device
Declaration
public void GenerateMouseEvent(int buttons, InputPointerType type, int x, int y)
Parameters
Type | Name | Description |
---|---|---|
int | buttons | The number of button. |
InputPointerType | type | The pointer type. |
int | x | x coordination to move. |
int | y | y coordination to move. |
Remarks
This is not for use by third-party applications.
GenerateTouchEvent(int, InputTouchType, int, int)
Generate a touch event using a opened device
Declaration
public void GenerateTouchEvent(int index, InputTouchType type, int x, int y)
Parameters
Type | Name | Description |
---|---|---|
int | index | The index of touched finger. |
InputTouchType | type | The touch type. |
int | x | The x axis of touch point. |
int | y | The y axis of touch point. |
Remarks
This is not for use by third-party applications.