Skip to content

Commit

Permalink
On Wayland, fix nightly warnings
Browse files Browse the repository at this point in the history
The new analysis suggests that we can remove mut.
  • Loading branch information
kchibisov committed May 3, 2023
1 parent f980ed7 commit 9938327
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/platform_impl/linux/wayland/seat/keyboard/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ impl KeyboardHandler for WinitState {
modifiers: Modifiers,
) {
let modifiers = ModifiersState::from(modifiers);
let mut seat_state = self.seats.get_mut(&keyboard.seat().id()).unwrap();
let seat_state = self.seats.get_mut(&keyboard.seat().id()).unwrap();
seat_state.modifiers = modifiers;

// NOTE: part of the workaround from `fn enter`, see it above.
Expand Down
2 changes: 1 addition & 1 deletion src/platform_impl/linux/wayland/seat/touch/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ impl TouchHandler for WinitState {
let seat_state = self.seats.get_mut(&touch.seat().id()).unwrap();

// Remove the touch point.
let mut touch_point = match seat_state.touch_map.get_mut(&id) {
let touch_point = match seat_state.touch_map.get_mut(&id) {
Some(touch_point) => touch_point,
None => return,
};
Expand Down

0 comments on commit 9938327

Please sign in to comment.