update control API.

This commit is contained in:
Miroslav Šedivý 2022-01-30 21:09:13 +01:00
parent 7d779396ba
commit b2e1eba4c2

View File

@ -37,15 +37,15 @@ export class NekoControl extends EventEmitter<NekoControlEvents> {
this._connection.websocket.send(EVENT.CONTROL_RELEASE) this._connection.websocket.send(EVENT.CONTROL_RELEASE)
} }
public keypress(keysym: number) { public keyPress(keysym: number) {
this._connection.websocket.send(EVENT.CONTROL_KEYPRESS, { keysym } as message.ControlKey) this._connection.websocket.send(EVENT.CONTROL_KEYPRESS, { keysym } as message.ControlKey)
} }
public keydown(keysym: number) { public keyDown(keysym: number) {
this._connection.websocket.send(EVENT.CONTROL_KEYDOWN, { keysym } as message.ControlKey) this._connection.websocket.send(EVENT.CONTROL_KEYDOWN, { keysym } as message.ControlKey)
} }
public keyup(keysym: number) { public keyUp(keysym: number) {
this._connection.websocket.send(EVENT.CONTROL_KEYUP, { keysym } as message.ControlKey) this._connection.websocket.send(EVENT.CONTROL_KEYUP, { keysym } as message.ControlKey)
} }