grabs/moving: cleanup drag in tiling layer if window doesn't exist

This commit is contained in:
Ian Douglas Scott 2025-07-16 19:10:32 -07:00 committed by Jeremy Soller
parent 813dd0ce1c
commit 67d0a825d1

View file

@ -786,6 +786,7 @@ impl Drop for MoveGrab {
let previous = self.previous;
let window = self.window.clone();
let is_touch_grab = matches!(self.start_data, GrabStartData::Touch(_));
let cursor_output = self.cursor_output.clone();
let _ = self.evlh.0.insert_idle(move |state| {
let position: Option<(CosmicMapped, Point<i32, Global>)> = if let Some(grab_state) =
@ -889,6 +890,14 @@ impl Drop for MoveGrab {
}
}
} else {
let mut shell = state.common.shell.write();
shell
.workspaces
.active_mut(&cursor_output)
.unwrap()
.tiling_layer
.cleanup_drag();
shell.set_overview_mode(None, state.common.event_loop_handle.clone());
None
}
} else {