overlay: Directly create cairo_region

Instead of doing a cairo_region_create + union, just pass the rect
directly to cairo_region_create_rectangle
This commit is contained in:
Timm Bäder 2019-01-13 07:47:53 +01:00
parent 69bc42f444
commit 44a2a49f31

View File

@ -740,8 +740,7 @@ gtk_overlay_snapshot (GtkWidget *widget,
rect.x = rect.y = 0;
rect.width = main_alloc.width;
rect.height = main_alloc.height;
clip = cairo_region_create ();
cairo_region_union_rectangle (clip, &rect);
clip = cairo_region_create_rectangle (&rect);
}
cairo_region_subtract_rectangle (clip, (cairo_rectangle_int_t *)&alloc);
}