From 574af5597c91db9cf3df641883470da4a3cb93e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Tue, 3 Jan 2006 11:36:45 +0000 Subject: [PATCH] Floating windows start with 0 workspaces - probably didn't matter, though, as freshly added windows are hidden anyway. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15810 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/servers/app/Desktop.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/servers/app/Desktop.cpp b/src/servers/app/Desktop.cpp index eedf4e84ac..7849952cc9 100644 --- a/src/servers/app/Desktop.cpp +++ b/src/servers/app/Desktop.cpp @@ -1070,8 +1070,6 @@ Desktop::SendWindowBehind(WindowLayer* window, WindowLayer* behindOf) dirty.Exclude(&clean); MarkDirty(dirty); - // TODO: if this window has any floating windows, remove them here - _UpdateFronts(); SetFocusWindow(FrontWindow()); //_WindowsChanged(); @@ -1386,6 +1384,10 @@ Desktop::SetWindowWorkspaces(WindowLayer* window, uint32 workspaces) } +/*! \brief Adds the window to the desktop. + At this point, the window is still hidden and must be shown explicetly + via ShowWindow(). +*/ void Desktop::AddWindow(WindowLayer *window) { @@ -1400,7 +1402,8 @@ Desktop::AddWindow(WindowLayer *window) window->SetWorkspaces(workspace_to_workspaces(CurrentWorkspace())); } else { // subset windows are visible on all workspaces their subset is on - window->SetWorkspaces(window->SubsetWorkspaces()); + // (but floating windows default to not visible) + window->SetWorkspaces(window->IsModal() ? window->SubsetWorkspaces() : 0); } _ChangeWindowWorkspaces(window, 0, window->Workspaces());