mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-24 20:51:10 +00:00
gdk: Clamp frame region to surface size
The region may be larger than the surface's size, but many rendering APIs require the size to be clamped. Fixes #5812
This commit is contained in:
parent
4a1598dc2a
commit
b530ade8c6
@ -371,6 +371,12 @@ gdk_draw_context_begin_frame_full (GdkDrawContext *context,
|
||||
priv->surface->paint_context = g_object_ref (context);
|
||||
|
||||
GDK_DRAW_CONTEXT_GET_CLASS (context)->begin_frame (context, prefers_high_depth, priv->frame_region);
|
||||
|
||||
cairo_region_intersect_rectangle (priv->frame_region,
|
||||
&(cairo_rectangle_int_t) {
|
||||
0, 0,
|
||||
priv->surface->width, priv->surface->height
|
||||
});
|
||||
}
|
||||
|
||||
#ifdef HAVE_SYSPROF
|
||||
|
Loading…
Reference in New Issue
Block a user