Gamepad: Remove GamepadList and fix dropped connection event on startup (#31684)

* Replace GamepadList

* Fix initial gamepad connection event from gilrs getting dropped

* Fix gamepad reconnection issues, use MutNullableDom

* Reduce some repetition in handle_gamepad_events

* Address feedback, move some steps to navigator methods

* Refactor internal navigator gamepad methods

* Add note re: unused gilrs index, adjust navigator gamepad methods
This commit is contained in:
Daniel Adams 2024-04-07 23:43:48 -10:00 committed by GitHub
parent ddbec46e1f
commit e38b34a629
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 91 additions and 146 deletions

View file

@ -199,6 +199,10 @@ impl Gamepad {
}
}
pub fn index(&self) -> i32 {
self.index.get()
}
pub fn update_index(&self, index: i32) {
self.index.set(index);
}