(&mut self, index: usize)
| 227 | pub fn joycon_side(&self, side: JoyConSide) -> Option<&JoyConState> { |
| 228 | self.joycons.iter().find(|jc| jc.side() == side) |
| 229 | } |
| 230 | |
| 231 | /// Find the first mutable Joy-Con with a matching side. |
| 232 | #[inline] |
| 233 | pub fn joycon_side_mut(&mut self, side: JoyConSide) -> Option<&mut JoyConState> { |
| 234 | self.joycons.iter_mut().find(|jc| jc.side() == side) |
| 235 | } |
| 236 | |
| 237 | /// Return a mutable gamepad slot, creating empty slots as needed. |
no test coverage detected