diff --git a/src/shell/grabs/moving.rs b/src/shell/grabs/moving.rs index 8a7d0f9c4..46f887b87 100644 --- a/src/shell/grabs/moving.rs +++ b/src/shell/grabs/moving.rs @@ -783,6 +783,7 @@ impl Drop for MoveGrab { let previous = self.previous.clone(); 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)> = if let Some(grab_state) = @@ -886,6 +887,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 { diff --git a/src/shell/layout/tiling/mod.rs b/src/shell/layout/tiling/mod.rs index a8bfd26b1..a780c1858 100644 --- a/src/shell/layout/tiling/mod.rs +++ b/src/shell/layout/tiling/mod.rs @@ -3339,6 +3339,25 @@ impl TilingLayout { let last_overview_hover = &mut self.last_overview_hover; let tree = &self.queue.trees.back().unwrap().0; let Some(root) = tree.root_node_id() else { + if matches!( + overview.active_trigger(), + Some(Trigger::Pointer(_) | Trigger::Touch(_)) + ) { + if location_f64.is_some() { + let mut tree = tree.copy_clone(); + tree.insert( + Node::new(Data::Placeholder { + id: Id::new(), + last_geometry: Rectangle::from_size((100, 100).into()), + type_: PlaceholderType::DropZone, + }), + InsertBehavior::AsRoot, + ) + .unwrap(); + let blocker = TilingLayout::update_positions(&self.output, &mut tree, gaps); + self.queue.push_tree(tree, ANIMATION_DURATION, blocker); + } + } return; };