diff --git a/src/shell/mod.rs b/src/shell/mod.rs index 83845598..326b064b 100644 --- a/src/shell/mod.rs +++ b/src/shell/mod.rs @@ -2491,13 +2491,11 @@ impl Shell { movement: zoom_config.view_moves, }); - if level > 1.0 { - self.update_focal_point( - seat, - seat.get_pointer().unwrap().current_location().as_global(), - zoom_config.view_moves, - ); - } + self.update_focal_point( + seat, + seat.get_pointer().unwrap().current_location().as_global(), + zoom_config.view_moves, + ); } pub fn update_focal_point( diff --git a/src/shell/zoom.rs b/src/shell/zoom.rs index a8da3561..ef81053f 100644 --- a/src/shell/zoom.rs +++ b/src/shell/zoom.rs @@ -319,7 +319,7 @@ impl ZoomState { ZoomMovement::Centered => { let center = (output_geometry.size / 2.).to_point(); - if level <= 1.0 + f64::EPSILON { + if level == 1.0 { // Prevent focal point jumping to top-left corner (0, 0) on zoom out output_state_ref.focal_point = center; return;