summaryrefslogtreecommitdiff
path: root/gtk/gtkcssnumbervalue.c
diff options
context:
space:
mode:
Diffstat (limited to 'gtk/gtkcssnumbervalue.c')
-rw-r--r--gtk/gtkcssnumbervalue.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/gtk/gtkcssnumbervalue.c b/gtk/gtkcssnumbervalue.c
index 009c9704f7..927e9bfce9 100644
--- a/gtk/gtkcssnumbervalue.c
+++ b/gtk/gtkcssnumbervalue.c
@@ -39,19 +39,16 @@ static double
get_base_font_size (guint property_id,
GtkStyleProviderPrivate *provider,
GtkCssStyle *style,
- GtkCssStyle *parent_style,
- GtkCssDependencies *dependencies)
+ GtkCssStyle *parent_style)
{
if (property_id == GTK_CSS_PROPERTY_FONT_SIZE)
{
- *dependencies = GTK_CSS_DEPENDS_ON_PARENT;
if (parent_style)
return _gtk_css_number_value_get (gtk_css_style_get_value (parent_style, GTK_CSS_PROPERTY_FONT_SIZE), 100);
else
return _gtk_css_font_size_get_default (provider);
}
- *dependencies = GTK_CSS_DEPENDS_ON_FONT_SIZE;
return _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_FONT_SIZE), 100);
}
@@ -60,8 +57,7 @@ gtk_css_value_number_compute (GtkCssValue *number,
guint property_id,
GtkStyleProviderPrivate *provider,
GtkCssStyle *style,
- GtkCssStyle *parent_style,
- GtkCssDependencies *dependencies)
+ GtkCssStyle *parent_style)
{
GtkBorderStyle border_style;
@@ -106,7 +102,7 @@ gtk_css_value_number_compute (GtkCssValue *number,
/* percentages for font sizes are computed, other percentages aren't */
if (property_id == GTK_CSS_PROPERTY_FONT_SIZE)
return _gtk_css_number_value_new (number->value / 100.0 *
- get_base_font_size (property_id, provider, style, parent_style, dependencies),
+ get_base_font_size (property_id, provider, style, parent_style),
GTK_CSS_PX);
case GTK_CSS_NUMBER:
case GTK_CSS_PX:
@@ -134,13 +130,13 @@ gtk_css_value_number_compute (GtkCssValue *number,
break;
case GTK_CSS_EM:
return _gtk_css_number_value_new (number->value *
- get_base_font_size (property_id, provider, style, parent_style, dependencies),
+ get_base_font_size (property_id, provider, style, parent_style),
GTK_CSS_PX);
break;
case GTK_CSS_EX:
/* for now we pretend ex is half of em */
return _gtk_css_number_value_new (number->value * 0.5 *
- get_base_font_size (property_id, provider, style, parent_style, dependencies),
+ get_base_font_size (property_id, provider, style, parent_style),
GTK_CSS_PX);
case GTK_CSS_RAD:
return _gtk_css_number_value_new (number->value * 360.0 / (2 * G_PI),