[metacity] Revert "theme: fix missing background color"



commit 33cdc8a6376573a4d0c1e3cdf02a1fac8e1b5046
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Sun Jan 24 01:00:05 2016 +0200

    Revert "theme: fix missing background color"

 src/ui/theme.c |   33 +++------------------------------
 1 files changed, 3 insertions(+), 30 deletions(-)
---
diff --git a/src/ui/theme.c b/src/ui/theme.c
index 20f4546..31a8f8f 100644
--- a/src/ui/theme.c
+++ b/src/ui/theme.c
@@ -1686,9 +1686,9 @@ meta_color_spec_new_gtk (MetaGtkColorComponent component,
 }
 
 static void
-get_background_color_real (GtkStyleContext *context,
-                           GtkStateFlags    state,
-                           GdkRGBA         *color)
+get_background_color (GtkStyleContext *context,
+                      GtkStateFlags    state,
+                      GdkRGBA         *color)
 {
   GdkRGBA *c;
 
@@ -1704,33 +1704,6 @@ get_background_color_real (GtkStyleContext *context,
   gdk_rgba_free (c);
 }
 
-static void
-get_background_color (GtkStyleContext *context,
-                      GtkStateFlags    state,
-                      GdkRGBA         *color)
-{
-  GdkRGBA empty = { 0.0, 0.0, 0.0, 0.0 };
-  GdkRGBA rgba;
-
-  get_background_color_real (context, state, &rgba);
-
-  if (gdk_rgba_equal (&rgba, &empty))
-    {
-      GtkWidget *toplevel;
-      GtkStyleContext *tmp;
-
-      toplevel = gtk_window_new (GTK_WINDOW_TOPLEVEL);
-      tmp = gtk_widget_get_style_context (toplevel);
-
-      gtk_style_context_set_state (tmp, state);
-      get_background_color_real (tmp, state, &rgba);
-
-      gtk_widget_destroy (toplevel);
-    }
-
-  *color = rgba;
-}
-
 /* Based on set_color() in gtkstyle.c */
 #define LIGHTNESS_MULT 1.3
 #define DARKNESS_MULT  0.7


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