From 20941aca53753ab86f9eea9d2dde54456a0c77ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 27 May 2011 16:47:45 +0200 Subject: [PATCH] Fix regression of setting a window to all desktops The logic to prevent errornous desktops broke setting a window to all desktops through the task manager. For some reason all desktops is -1 which is of course less than 1 ;-) --- workspace.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workspace.cpp b/workspace.cpp index cb73cc9414..a773700fe8 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -1683,7 +1683,7 @@ void Workspace::setNumberOfDesktops(int n) */ void Workspace::sendClientToDesktop(Client* c, int desk, bool dont_activate) { - if (desk < 1 || desk > numberOfDesktops()) + if ((desk < 1 && desk != NET::OnAllDesktops) || desk > numberOfDesktops()) return; int old_desktop = c->desktop(); bool was_on_desktop = c->isOnDesktop(desk) || c->isOnAllDesktops();