- If the event window was set the window was moved also if the moveFocusWindow flag was not set.
- Use ProcessDirtyRegion to redraw the dirty region.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39707 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Clemens Zeidler 2010-12-02 20:51:38 +00:00
parent 15352f8de6
commit dc2dd40caa
2 changed files with 8 additions and 15 deletions

View File

@ -1123,18 +1123,7 @@ DefaultWindowBehaviour::_SetBorderHighlights(int8 horizontal, int8 vertical,
}
// invalidate the affected regions
dirtyRegion.IntersectWith(&fWindow->VisibleRegion());
BRect dirtyRect(dirtyRegion.Frame());
if (dirtyRect.IsValid()) {
DrawingEngine* engine = decorator->GetDrawingEngine();
engine->LockParallelAccess();
engine->ConstrainClippingRegion(&dirtyRegion);
decorator->Draw(dirtyRect);
engine->UnlockParallelAccess();
}
fWindow->ProcessDirtyRegion(dirtyRegion);
}
}

View File

@ -3357,9 +3357,13 @@ Desktop::_SetWorkspace(int32 index, bool moveFocusWindow)
int32 previousIndex = fCurrentWorkspace;
rgb_color previousColor = fWorkspaces[fCurrentWorkspace].Color();
bool movedMouseEventWindow = false;
Window* movedWindow = fMouseEventWindow;
if (movedWindow == NULL && moveFocusWindow)
movedWindow = FocusWindow();
Window* movedWindow = NULL;
if (moveFocusWindow) {
if (fMouseEventWindow != NULL)
movedWindow = fMouseEventWindow;
else
movedWindow = FocusWindow();
}
if (movedWindow != NULL) {
if (movedWindow->IsNormal()) {