|
@@ -77,27 +77,25 @@ static const uint DIRTY_BLOCK_WIDTH =
|
|
|
static uint _dirty_bytes_per_line = 0;
|
|
|
static byte *_dirty_blocks = NULL;
|
|
|
extern uint _dirty_block_colour;
|
|
|
|
|
|
void GfxScroll(int left, int top, int width, int height, int xo, int yo)
|
|
|
{
|
|
|
Blitter *blitter = BlitterFactory::GetCurrentBlitter();
|
|
|
|
|
|
if (xo == 0 && yo == 0) return;
|
|
|
|
|
|
if (_cursor.visible) UndrawMouseCursor();
|
|
|
|
|
|
#ifdef ENABLE_NETWORK
|
|
|
if (_networking) NetworkUndrawChatMessage();
|
|
|
#endif /* ENABLE_NETWORK */
|
|
|
|
|
|
blitter->ScrollBuffer(_screen.dst_ptr, left, top, width, height, xo, yo);
|
|
|
/* This part of the screen is now dirty. */
|
|
|
VideoDriver::GetInstance()->MakeDirty(left, top, width, height);
|
|
|
}
|
|
|
|
|
|
|
|
|
/**
|
|
|
* Applies a certain FillRectMode-operation to a rectangle [left, right] x [top, bottom] on the screen.
|
|
|
*
|
|
|
* @pre dpi->zoom == ZOOM_LVL_NORMAL, right >= left, bottom >= top
|
|
|
* @param left Minimum X (inclusive)
|
|
@@ -1279,27 +1277,25 @@ void DrawMouseCursor()
|
|
|
void RedrawScreenRect(int left, int top, int right, int bottom)
|
|
|
{
|
|
|
assert(right <= _screen.width && bottom <= _screen.height);
|
|
|
if (_cursor.visible) {
|
|
|
if (right > _cursor.draw_pos.x &&
|
|
|
left < _cursor.draw_pos.x + _cursor.draw_size.x &&
|
|
|
bottom > _cursor.draw_pos.y &&
|
|
|
top < _cursor.draw_pos.y + _cursor.draw_size.y) {
|
|
|
UndrawMouseCursor();
|
|
|
}
|
|
|
}
|
|
|
|
|
|
#ifdef ENABLE_NETWORK
|
|
|
if (_networking) NetworkUndrawChatMessage();
|
|
|
#endif /* ENABLE_NETWORK */
|
|
|
|
|
|
DrawOverlappedWindowForAll(left, top, right, bottom);
|
|
|
|
|
|
VideoDriver::GetInstance()->MakeDirty(left, top, right - left, bottom - top);
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* Repaints the rectangle blocks which are marked as 'dirty'.
|
|
|
*
|
|
|
* @see SetDirtyBlocks
|
|
|
*/
|
|
|
void DrawDirtyBlocks()
|