mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-09-25 19:13:46 +08:00
fix a compositing bug when the wallpaper is empty
This commit is contained in:
@@ -228,6 +228,7 @@ static void composite_wallpaper_rect (CompositorCtxt* ctxt,
|
||||
}
|
||||
}
|
||||
else {
|
||||
SelectClipRect (HDC_SCREEN_SYS, dirty_rc);
|
||||
SetBrushColor (HDC_SCREEN_SYS,
|
||||
GetWindowElementPixelEx (HWND_DESKTOP, HDC_SCREEN_SYS,
|
||||
WE_BGC_DESKTOP));
|
||||
|
||||
+3
-2
@@ -240,8 +240,10 @@ static GAL_Surface* create_wp_surface(GAL_Surface* screen)
|
||||
req.len_data = strlen (SYSSF_WALLPAPER_PATTER) + 1;
|
||||
|
||||
if ((ClientRequestEx2 (&req, NULL, 0, -1,
|
||||
&info, sizeof (SHAREDSURFINFO), &fd) < 0) || (fd < 0))
|
||||
&info, sizeof (SHAREDSURFINFO), &fd) < 0) || (fd < 0)) {
|
||||
_WRN_PRINTF ("creating an empty wallpaper pattern surface\n");
|
||||
goto empty;
|
||||
}
|
||||
|
||||
_DBG_PRINTF ("REQID_GETSHAREDSURFACE: size (%lu), flags (0x%x), fd: %d\n",
|
||||
info.size, info.flags, fd);
|
||||
@@ -253,7 +255,6 @@ static GAL_Surface* create_wp_surface(GAL_Surface* screen)
|
||||
}
|
||||
|
||||
empty:
|
||||
_DBG_PRINTF ("creating an empty wallpaper pattern surface\n");
|
||||
if (IsServer()) {
|
||||
return GAL_CreateRGBSurface (GAL_SWSURFACE, 0, 0,
|
||||
screen->format->BitsPerPixel,
|
||||
|
||||
Reference in New Issue
Block a user