fixed the frame buffer version for real
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15134 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -55,6 +55,7 @@ Desktop::~Desktop()
|
|||||||
void
|
void
|
||||||
Desktop::Draw(BRect updateRect)
|
Desktop::Draw(BRect updateRect)
|
||||||
{
|
{
|
||||||
|
#if RUN_WITH_FRAME_BUFFER
|
||||||
// since parts of the view might have been exposed,
|
// since parts of the view might have been exposed,
|
||||||
// we need a clipping rebuild
|
// we need a clipping rebuild
|
||||||
if (LockClipping()) {
|
if (LockClipping()) {
|
||||||
@@ -64,16 +65,20 @@ Desktop::Draw(BRect updateRect)
|
|||||||
|
|
||||||
UnlockClipping();
|
UnlockClipping();
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if (fDrawingEngine->Lock()) {
|
if (fDrawingEngine->Lock()) {
|
||||||
fDrawingEngine->SetHighColor(51, 102, 152);
|
fDrawingEngine->SetHighColor(51, 102, 152);
|
||||||
fDrawingEngine->FillRegion(&fBackgroundRegion);
|
fDrawingEngine->FillRegion(&fBackgroundRegion);
|
||||||
fDrawingEngine->Unlock();
|
fDrawingEngine->Unlock();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if RUN_WITH_FRAME_BUFFER
|
||||||
// trigger redrawing windows
|
// trigger redrawing windows
|
||||||
BRegion update(updateRect);
|
BRegion update(updateRect);
|
||||||
update.Exclude(&fBackgroundRegion);
|
update.Exclude(&fBackgroundRegion);
|
||||||
MarkDirty(&update);
|
MarkDirty(&update);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// MouseDown
|
// MouseDown
|
||||||
@@ -108,12 +113,15 @@ Desktop::MouseDown(BPoint where, uint32 buttons)
|
|||||||
} else {
|
} else {
|
||||||
// complete redraw
|
// complete redraw
|
||||||
#if RUN_WITH_FRAME_BUFFER
|
#if RUN_WITH_FRAME_BUFFER
|
||||||
// TODO: broken
|
if (fDrawingEngine->Lock()) {
|
||||||
BRegion region(fDrawingEngine->Bounds());
|
BRegion region(fDrawingEngine->Bounds());
|
||||||
MarkDirty(®ion);
|
fDrawingEngine->Unlock();
|
||||||
region = fBackgroundRegion;
|
|
||||||
fBackgroundRegion.MakeEmpty();
|
MarkDirty(®ion);
|
||||||
_SetBackground(®ion);
|
region = fBackgroundRegion;
|
||||||
|
fBackgroundRegion.MakeEmpty();
|
||||||
|
_SetBackground(®ion);
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
fDrawingEngine->MarkDirty();
|
fDrawingEngine->MarkDirty();
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user