only call HandleDirectConnection() if the window is not hidden. Fixes bug #4234

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32369 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stefano Ceccherini 2009-08-14 15:47:36 +00:00
parent 0d4487f933
commit 1c8695a627

View File

@ -1204,7 +1204,7 @@ Window::_AlterDeltaForSnap(BPoint& delta, bigtime_t now)
void
Window::WorkspaceActivated(int32 index, bool active)
{
if (!active)
if (!active && !IsHidden())
fWindow->HandleDirectConnection(B_DIRECT_STOP);
BMessage activatedMsg(B_WORKSPACE_ACTIVATED);
@ -1214,7 +1214,7 @@ Window::WorkspaceActivated(int32 index, bool active)
ServerWindow()->SendMessageToClient(&activatedMsg);
if (active)
if (active && !IsHidden())
fWindow->HandleDirectConnection(B_DIRECT_START | B_BUFFER_RESET);
}