summaryrefslogtreecommitdiff
path: root/gtk/gtkcssimagevalue.c
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2013-06-27 18:26:05 +0200
committerAlexander Larsson <alexl@redhat.com>2013-07-03 14:39:25 +0200
commitaf2c40bd54149237cd4ab998b5515167018fdc47 (patch)
tree09b605f0a8192ea4215863cdca2082eaf263d3a8 /gtk/gtkcssimagevalue.c
parent38e1748df89ef0a92b050f77529cd42cea9b3caa (diff)
downloadgtk+-af2c40bd54149237cd4ab998b5515167018fdc47.tar.gz
css: Add a scale argument to css-value compute vfunc
We need to be able to compute different GtkCssImage values depending on the scale, and we need this at compute time so that we don't need to read any images other than the scale in used (to e.g. calculate the image size). GtkStyleProviderPrivate is shared for all style contexts, so its not right.
Diffstat (limited to 'gtk/gtkcssimagevalue.c')
-rw-r--r--gtk/gtkcssimagevalue.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkcssimagevalue.c b/gtk/gtkcssimagevalue.c
index dac0c2fac8..4dcba24e48 100644
--- a/gtk/gtkcssimagevalue.c
+++ b/gtk/gtkcssimagevalue.c
@@ -37,6 +37,7 @@ static GtkCssValue *
gtk_css_value_image_compute (GtkCssValue *value,
guint property_id,
GtkStyleProviderPrivate *provider,
+ int scale,
GtkCssComputedValues *values,
GtkCssComputedValues *parent_values,
GtkCssDependencies *dependencies)
@@ -48,7 +49,7 @@ gtk_css_value_image_compute (GtkCssValue *value,
if (image == NULL)
return _gtk_css_value_ref (value);
- computed = _gtk_css_image_compute (image, property_id, provider, values, parent_values, dependencies);
+ computed = _gtk_css_image_compute (image, property_id, provider, scale, values, parent_values, dependencies);
if (computed == image)
{