shell: don't accidentally reset zoom when using multiple seats (theoretically)

This commit is contained in:
Victoria Brekenfeld 2025-02-04 16:47:44 +01:00 • committed by Victoria Brekenfeld
parent effd67d498
commit 15c5e3fe26

View file

@ -2079,7 +2079,7 @@ impl Shell {
return; return;
} }
let previous_level = if let Some(old_state) = self.zoom_state.take() { let previous_level = if let Some(old_state) = self.zoom_state.as_ref() {
if &old_state.seat != seat { if &old_state.seat != seat {
return; return;
} }
@ -2092,7 +2092,7 @@ impl Shell {
OutputZoomState::new(seat, output, movement, level); OutputZoomState::new(seat, output, movement, level);
} }
} }
1.0 1.
}; };
self.zoom_state = Some(ZoomState { self.zoom_state = Some(ZoomState {