Skip to main content

Interface: Listener

keyboard/KeyboardHandler.internal.Listener

Describes a keyboard listener

Properties

displayOptions

displayOptions: DisplayOptions

How to indicate to the user that the listener is active

Defined in

keyboard/KeyboardHandler.ts:20

Methods

handleCancelled

handleCancelled(): void

This function will be called if the listener is canceled (eg if the user has cursorless.keyboard.escape bound to escape and they press escape)

Returns

void

Defined in

keyboard/KeyboardHandler.ts:34


handleInput

handleInput(text): Promise<unknown>

This function will be called anytime the user presses a key while this listener is active

Parameters

NameTypeDescription
textstringThe key pressed

Returns

Promise<unknown>

Defined in

keyboard/KeyboardHandler.ts:27