]> Pileus Git - ~andy/gtk/blobdiff - gtk/gtkcssrgbavalue.c
gtkfilechooserbutton: In tests, allow the possibility of doing unselect_all
[~andy/gtk] / gtk / gtkcssrgbavalue.c
index fc1642c392a0cf7a50c2508fe7cb9f0c752b4234..fb52acefa5052105a33c444cf4712778bdcecc10 100644 (file)
@@ -21,7 +21,6 @@
 
 #include "gtkcssstylepropertyprivate.h"
 #include "gtkstylecontextprivate.h"
-#include "gtksymboliccolorprivate.h"
 
 struct _GtkCssValue {
   GTK_CSS_VALUE_BASE
@@ -35,9 +34,12 @@ gtk_css_value_rgba_free (GtkCssValue *value)
 }
 
 static GtkCssValue *
-gtk_css_value_rgba_compute (GtkCssValue     *value,
-                            guint            property_id,
-                            GtkStyleContext *context)
+gtk_css_value_rgba_compute (GtkCssValue             *value,
+                            guint                    property_id,
+                            GtkStyleProviderPrivate *provider,
+                            GtkCssComputedValues    *values,
+                            GtkCssComputedValues    *parent_values,
+                            GtkCssDependencies      *dependencies)
 {
   return _gtk_css_value_ref (value);
 }
@@ -52,6 +54,7 @@ gtk_css_value_rgba_equal (const GtkCssValue *rgba1,
 static GtkCssValue *
 gtk_css_value_rgba_transition (GtkCssValue *start,
                                GtkCssValue *end,
+                               guint        property_id,
                                double       progress)
 {
   GdkRGBA transition;
@@ -102,41 +105,3 @@ _gtk_css_rgba_value_get_rgba (const GtkCssValue *rgba)
 
   return &rgba->rgba;
 }
-
-GtkCssValue *
-_gtk_css_rgba_value_compute_from_symbolic (GtkCssValue     *symbolic,
-                                           GtkCssValue     *fallback,
-                                           GtkStyleContext *context,
-                                           gboolean         for_color_property)
-{
-  GtkCssValue *resolved, *current;
-
-  g_return_val_if_fail (symbolic != NULL, NULL);
-
-  /* The computed value of the ‘currentColor’ keyword is the computed
-   * value of the ‘color’ property. If the ‘currentColor’ keyword is
-   * set on the ‘color’ property itself, it is treated as ‘color: inherit’. 
-   */
-  if (for_color_property)
-    {
-      GtkStyleContext *parent = gtk_style_context_get_parent (context);
-
-      if (parent)
-        current = _gtk_style_context_peek_property (parent, GTK_CSS_PROPERTY_COLOR);
-      else
-        current = _gtk_css_style_property_get_initial_value (_gtk_css_style_property_lookup_by_id (GTK_CSS_PROPERTY_COLOR));
-    }
-  else
-    {
-      current = _gtk_style_context_peek_property (context, GTK_CSS_PROPERTY_COLOR);
-    }
-  
-  resolved = _gtk_style_context_resolve_color_value (context, current, symbolic);
-
-  if (resolved == NULL)
-    return _gtk_css_rgba_value_compute_from_symbolic (fallback, NULL, context, for_color_property);
-
-  g_assert (resolved->class == &GTK_CSS_VALUE_RGBA);
-  return resolved;
-}
-