Allow dropping window onto toplevel list area
Fixes https://github.com/pop-os/cosmic-workspaces-epoch/issues/53.
This commit is contained in:
parent
6838bd60be
commit
88b35e3027
3 changed files with 31 additions and 8 deletions
20
src/main.rs
20
src/main.rs
|
|
@ -484,14 +484,18 @@ impl Application for App {
|
|||
}
|
||||
Msg::DndWorkspaceDrop(_toplevel) => {
|
||||
if let Some((DragSurface::Toplevel(handle), _)) = &self.drag_surface {
|
||||
if let Some(DropTarget::WorkspaceSidebarEntry(workspace, output)) =
|
||||
self.drop_target.take()
|
||||
{
|
||||
self.send_wayland_cmd(backend::Cmd::MoveToplevelToWorkspace(
|
||||
handle.clone(),
|
||||
workspace,
|
||||
output,
|
||||
));
|
||||
match self.drop_target.take() {
|
||||
Some(
|
||||
DropTarget::WorkspaceSidebarEntry(workspace, output)
|
||||
| DropTarget::OutputToplevels(workspace, output),
|
||||
) => {
|
||||
self.send_wayland_cmd(backend::Cmd::MoveToplevelToWorkspace(
|
||||
handle.clone(),
|
||||
workspace,
|
||||
output,
|
||||
));
|
||||
}
|
||||
None => {}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue