mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-10 10:50:10 +00:00
Use cairo_push_group() to mix backgrounds during transitions
It also helps remove the cairo_clip() call to achieve the rounded shape.
This commit is contained in:
parent
c990699922
commit
4c40349b92
@ -1498,10 +1498,8 @@ render_background_internal (GtkThemingEngine *engine,
|
||||
NULL);
|
||||
|
||||
running = gtk_theming_engine_state_is_running (engine, GTK_STATE_PRELIGHT, &progress);
|
||||
_cairo_round_rectangle_sides (cr, (gdouble) radius,
|
||||
x, y, width, height,
|
||||
SIDE_ALL, junction);
|
||||
cairo_clip (cr);
|
||||
|
||||
cairo_push_group (cr);
|
||||
|
||||
if (gtk_theming_engine_has_class (engine, "background"))
|
||||
{
|
||||
@ -1711,6 +1709,14 @@ render_background_internal (GtkThemingEngine *engine,
|
||||
cairo_pattern_destroy (mask);
|
||||
}
|
||||
|
||||
cairo_pop_group_to_source (cr);
|
||||
|
||||
_cairo_round_rectangle_sides (cr, (gdouble) radius,
|
||||
x, y, width, height,
|
||||
SIDE_ALL, junction);
|
||||
cairo_close_path (cr);
|
||||
cairo_fill (cr);
|
||||
|
||||
cairo_restore (cr);
|
||||
|
||||
gdk_rgba_free (bg_color);
|
||||
|
Loading…
Reference in New Issue
Block a user