Struct InputEvent
Tagged-union input event: read Kind first, then access the slot the discriminator names. Key and mouse events are zero-allocation; paste events carry a string for the pasted contents and so allocate one reference per event.
public readonly struct InputEvent
- Inherited Members
Constructors
InputEvent(KeyEvent)
public InputEvent(KeyEvent key)
Parameters
keyKeyEvent
InputEvent(MouseEvent)
public InputEvent(MouseEvent mouse)
Parameters
mouseMouseEvent
InputEvent(string)
public InputEvent(string paste)
Parameters
pastestring
Properties
Key
public KeyEvent Key { get; }
Property Value
Kind
public InputEventKind Kind { get; }
Property Value
Mouse
public MouseEvent Mouse { get; }
Property Value
Paste
public string? Paste { get; }