set dirty_rc empty initially

This commit is contained in:
Vincent Wei
2022-08-20 17:23:16 +08:00
parent 13d36a2785
commit 43e174a604
2 changed files with 4 additions and 3 deletions

View File

@@ -267,7 +267,7 @@ static int FB_EnterGraphicsMode (_THIS)
if (ioctl (ttyfd, KDSETMODE, KD_GRAPHICS) == -1) {
_WRN_PRINTF ("Error when setting the terminal (%s) "
"to graphics mode: %m\n", tty_dev);
_WRN_PRINTF ("It might is not a console.\n");
_WRN_PRINTF ("It might not be a console.\n");
goto fail;
}
#ifdef _MGRM_PROCESSES
@@ -797,7 +797,7 @@ static GAL_Surface *FB_SetVideoMode(_THIS, GAL_Surface *current,
dblbuff = TRUE;
}
}
#endif /* _MGSCHEMA_COMPOSITING */
#endif /* !IS_SHAREDFB_SCHEMA_PROC */
if (dblbuff) {
/* create shadow screen */
@@ -823,6 +823,7 @@ static GAL_Surface *FB_SetVideoMode(_THIS, GAL_Surface *current,
GAL_SetClipRect (this->hidden->real_screen, NULL);
GAL_SetColorKey (this->hidden->shadow_screen, 0, 0);
GAL_SetAlpha (this->hidden->shadow_screen, 0, 0);
SetRectEmpty (&this->hidden->dirty_rc);
}
else {
this->hidden->real_screen = NULL;

View File

@@ -81,7 +81,7 @@ struct GAL_PrivateVideoData {
GAL_Surface *real_screen, *shadow_screen;
RECT dirty_rc;
#if IS_COMPOSITING_SCHEMA
#ifdef _MGSCHEMA_COMPOSITING
/* Used to simulate the hardware cursor. */
GAL_Surface *cursor;
int csr_x, csr_y;