diff options
author | Benjamin Otte <otte@redhat.com> | 2011-12-29 13:38:45 +0100 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2012-01-09 18:37:50 +0100 |
commit | 242893a0315990c11bf5ce8908897e49df093081 (patch) | |
tree | fa06d5b0cebf8bcac9c05431aa18787c07d71110 /gtk/gtkcsslookup.c | |
parent | 0ac519e8a1b1429e9b6fbd657aa2be1d56ddd51c (diff) | |
download | gtk+-242893a0315990c11bf5ce8908897e49df093081.tar.gz |
css: Pass the parent context to _gtk_css_lookup_resolve()
This way, we can resolve inherit properties.
Diffstat (limited to 'gtk/gtkcsslookup.c')
-rw-r--r-- | gtk/gtkcsslookup.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gtk/gtkcsslookup.c b/gtk/gtkcsslookup.c index 5badd7b403..c5fd148826 100644 --- a/gtk/gtkcsslookup.c +++ b/gtk/gtkcsslookup.c @@ -94,6 +94,8 @@ _gtk_css_lookup_set (GtkCssLookup *lookup, /** * _gtk_css_lookup_resolve: * @lookup: the lookup + * @parent: the parent properties to look up inherited values from or %NULL + * if none * * Resolves the current lookup into a styleproperties object. This is done * by converting from the "winning declaration" to the "computed value". @@ -104,12 +106,14 @@ _gtk_css_lookup_set (GtkCssLookup *lookup, * Returns: a new #GtkStyleProperties **/ GtkStyleProperties * -_gtk_css_lookup_resolve (GtkCssLookup *lookup) +_gtk_css_lookup_resolve (GtkCssLookup *lookup, + GtkStyleContext *parent) { GtkStyleProperties *props; guint i, n; g_return_val_if_fail (lookup != NULL, NULL); + g_return_val_if_fail (parent == NULL || GTK_IS_STYLE_CONTEXT (parent), NULL); n = _gtk_style_property_get_count (); props = gtk_style_properties_new (); |