Revert "ngl: Remove duplicate check"

This reverts commit 1fd534ef1e.

This change revealed that we are not treating damage regions
correctly, and we regularly end up with
This commit is contained in:
Matthias Clasen 2021-03-19 13:17:02 -04:00
parent a33e32ef60
commit 830efa6ce2

View File

@ -173,7 +173,10 @@ get_render_region (GdkSurface *surface,
*/
damage = gdk_draw_context_get_frame_region (GDK_DRAW_CONTEXT (context));
/* If the extents match the full-scene, return NULL */
if (cairo_region_contains_rectangle (damage, &whole_surface) == CAIRO_REGION_OVERLAP_IN)
return NULL;
/* If the extents match the full-scene, do the same as above */
cairo_region_get_extents (damage, &extents);
if (gdk_rectangle_equal (&extents, &whole_surface))
return NULL;