Table of Contents

Class WindowInput

Namespace
Lime
Assembly
Lime.dll
public class WindowInput
Inheritance
WindowInput
Inherited Members

Constructors

WindowInput(IWindow)

public WindowInput(IWindow ownerWindow)

Parameters

ownerWindow IWindow

Properties

Changed

public bool Changed { get; }

Property Value

bool

DroppedFiles

Returns list of files dropped on the window. This list automatically being cleaned up after window update.

public List<string> DroppedFiles { get; }

Property Value

List<string>

MousePosition

The current mouse position in local coordinates. (read only)

public Vector2 MousePosition { get; }

Property Value

Vector2

MousePositionTransform

public Matrix32 MousePositionTransform { get; set; }

Property Value

Matrix32

TextInput

public string TextInput { get; }

Property Value

string

WheelScrollAmount

Indicates how much the mouse wheel was moved

public float WheelScrollAmount { get; }

Property Value

float

Methods

ConsumeKey(Key)

public void ConsumeKey(Key key)

Parameters

key Key

GetModifiers()

public Modifiers GetModifiers()

Returns

Modifiers

GetNumTouches()

public int GetNumTouches()

Returns

int

GetTouchPosition(int)

public Vector2 GetTouchPosition(int index)

Parameters

index int

Returns

Vector2

IsKeyPressed(Key)

Returns true while the user holds down the key identified by name. Think auto fire.

public bool IsKeyPressed(Key key)

Parameters

key Key

Returns

bool

IsMousePressed()

public bool IsMousePressed()

Returns

bool

IsMousePressed(int)

public bool IsMousePressed(int button)

Parameters

button int

Returns

bool

IsTouching(int)

public bool IsTouching(int index)

Parameters

index int

Returns

bool

MouseDesktopToLocal(Vector2)

Converts desktop mouse coordinates into transformed local mouse coordinates.

public Vector2 MouseDesktopToLocal(Vector2 desktopMousePosition)

Parameters

desktopMousePosition Vector2

Returns

Vector2

MouseLocalToDesktop(Vector2)

Converts transformed local mouse coordinates into desktop mouse coordinates.

public Vector2 MouseLocalToDesktop(Vector2 localMousePosition)

Parameters

localMousePosition Vector2

Returns

Vector2

WasDoubleClickPressed(int)

public bool WasDoubleClickPressed(int buttonIndex)

Parameters

buttonIndex int

Returns

bool

WasKeyPressed(Key)

Returns true during the frame the user starts pressing down the key identified by name.

public bool WasKeyPressed(Key key)

Parameters

key Key

Returns

bool

WasKeyReleased(Key)

Returns true during the frame the user releases the key identified by name.

public bool WasKeyReleased(Key key)

Parameters

key Key

Returns

bool

WasKeyRepeated(Key)

Returns true during the frame the user starts pressing down the key identified by name or key event was repeated.

public bool WasKeyRepeated(Key key)

Parameters

key Key

Returns

bool

WasMousePressed()

public bool WasMousePressed()

Returns

bool

WasMousePressed(int)

public bool WasMousePressed(int button)

Parameters

button int

Returns

bool

WasMouseReleased()

public bool WasMouseReleased()

Returns

bool

WasMouseReleased(int)

public bool WasMouseReleased(int button)

Parameters

button int

Returns

bool

WasTouchBegan(int)

public bool WasTouchBegan(int index)

Parameters

index int

Returns

bool

WasTouchEnded(int)

public bool WasTouchEnded(int index)

Parameters

index int

Returns

bool