1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-27 00:41:08 +02:00

* minor fixes for screen scrolling

This commit is contained in:
mateuszb
2010-08-23 16:13:30 +00:00
parent 6b8718b046
commit 7cad2364fe
7 changed files with 41 additions and 14 deletions

View File

@ -1277,4 +1277,23 @@ void CSDL_Ext::blitSurface( SDL_Surface * src, SDL_Rect * srcRect, SDL_Surface *
}
}
void CSDL_Ext::fillRect( SDL_Surface *dst, SDL_Rect *dstrect, Uint32 color )
{
SDL_Rect newRect;
if (dstrect)
{
newRect = *dstrect;
}
else
{
newRect = Rect(0, 0, dst->w, dst->h);
}
if (dst == screen)
{
newRect.x += screenLT.x;
newRect.y += screenLT.y;
}
SDL_FillRect(dst, &newRect, color);
}
SDL_Surface * CSDL_Ext::std32bppSurface = NULL;