diff --git a/src/shell/element/window.rs b/src/shell/element/window.rs index 699a84eb..017ae7a9 100644 --- a/src/shell/element/window.rs +++ b/src/shell/element/window.rs @@ -115,8 +115,8 @@ impl Focus { header_height: i32, location: Point, ) -> Option { - let loc = location.to_i32_round::(); let geo = surface.geometry(); + let loc = location.to_i32_round::() - geo.loc; if loc.y < 0 && loc.x < 0 { Some(Focus::ResizeTopLeft) } else if loc.y < 0 && loc.x >= geo.size.w {