Never do implicit paints for foreign windows

They don't need double buffer combination since they have no
client-side children, and creating pixmaps for them is risky
since they could disappear at any time.

May fix bug 598476 and 603652.
This commit is contained in:
Matthias Clasen 2009-12-08 10:09:04 -05:00
parent 105b007545
commit 0748cf563d

View File

@ -2611,6 +2611,14 @@ gdk_window_begin_implicit_paint (GdkWindow *window, GdkRectangle *rect)
private->implicit_paint != NULL)
return FALSE; /* Don't stack implicit paints */
/* Never do implicit paints for foreign windows, they don't need
* double buffer combination since they have no client side children,
* and creating pixmaps for them is risky since they could disappear
* at any time
*/
if (private->window_type == GDK_WINDOW_FOREIGN)
return FALSE;
paint = g_new (GdkWindowPaint, 1);
paint->region = gdk_region_new (); /* Empty */
paint->x_offset = rect->x;