summaryrefslogtreecommitdiff
path: root/gtk/gtkcssnode.c
diff options
context:
space:
mode:
authorTimm Bäder <mail@baedert.org>2019-08-24 10:09:41 +0200
committerTimm Bäder <mail@baedert.org>2019-09-09 17:36:24 +0200
commit514e60c1bb4ef1d0c5d6f74d102eb14a1d09da48 (patch)
tree0c8cf8eccc6255bd6bf9d33ba1a72df9aebec77b /gtk/gtkcssnode.c
parent32a256bd0374e96411437acb59a466abf4dfe90c (diff)
downloadgtk+-514e60c1bb4ef1d0c5d6f74d102eb14a1d09da48.tar.gz
cssnode: GtkCssAnimatedStyle->style is always a static style
Diffstat (limited to 'gtk/gtkcssnode.c')
-rw-r--r--gtk/gtkcssnode.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gtk/gtkcssnode.c b/gtk/gtkcssnode.c
index 039791e873..0cce324e05 100644
--- a/gtk/gtkcssnode.c
+++ b/gtk/gtkcssnode.c
@@ -25,6 +25,7 @@
#include "gtkmarshalers.h"
#include "gtksettingsprivate.h"
#include "gtktypebuiltins.h"
+#include "gtkprivate.h"
/*
* CSS nodes are the backbone of the GtkStyleContext implementation and
@@ -386,13 +387,12 @@ static gboolean
gtk_css_style_needs_recreation (GtkCssStyle *style,
GtkCssChange change)
{
+ gtk_internal_return_val_if_fail (GTK_IS_CSS_STATIC_STYLE (style), TRUE);
+
/* Try to avoid invalidating if we can */
if (change & GTK_CSS_RADICAL_CHANGE)
return TRUE;
- if (GTK_IS_CSS_ANIMATED_STYLE (style))
- style = GTK_CSS_ANIMATED_STYLE (style)->style;
-
if (gtk_css_static_style_get_change (GTK_CSS_STATIC_STYLE (style)) & change)
return TRUE;
else