Genymobile / genymotion-device-web-player

Genymotion Virtual Device Web Player
https://www.genymotion.com/
MIT License
104 stars 34 forks source link

Closing & reopening the webrtc connection loses the mouse & keyboard inputs #108

Closed skornous closed 1 month ago

skornous commented 1 month ago

Description

Since the rework of v4 a bug was present where if you closed & reopened the WebRTC WebSocket you'd lose the inputs from both mouse & keyboard.

After some tests it appears that unregistering the mouse & keyboard events in the store on WebSocket disconnection & then re-registering them when creating the peer connection (as for the touch & gamepad events) fixes this issue.

This PR is the aforementioned fix.

Sorry but as it's quite a technical issue, it's hard to provide a simple screen-record so you'll have to trust me on this 😬

Fixes #(no related issue)

Type of change

Checklist

skornous commented 1 month ago

Fix found elsewhere and this seems to to break some feature anyway, closing PR