[gtk/css-style-split-2: 33/34] dimensionvalue: Use direct access for css values



commit 14dd5229becca931353d7be61f3904b72927330f
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue Jan 28 11:03:54 2020 +0100

    dimensionvalue: Use direct access for css values

 gtk/gtkcssdimensionvalue.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkcssdimensionvalue.c b/gtk/gtkcssdimensionvalue.c
index d8e06af052..b54309d079 100644
--- a/gtk/gtkcssdimensionvalue.c
+++ b/gtk/gtkcssdimensionvalue.c
@@ -45,18 +45,18 @@ get_base_font_size_px (guint             property_id,
   if (property_id == GTK_CSS_PROPERTY_FONT_SIZE)
     {
       if (parent_style)
-        return _gtk_css_number_value_get (gtk_css_style_get_value (parent_style, 
GTK_CSS_PROPERTY_FONT_SIZE), 100);
+        return _gtk_css_number_value_get (parent_style->core->font_size, 100);
       else
         return gtk_css_font_size_get_default_px (provider, style);
     }
 
-  return _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_FONT_SIZE), 100);
+  return _gtk_css_number_value_get (style->core->font_size, 100);
 }
 
 static double
 get_dpi (GtkCssStyle *style)
 {
-  return _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_DPI), 96);
+  return _gtk_css_number_value_get (style->core->dpi, 96);
 }
 
 static GtkCssValue *


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]