[gnome-control-center] user-accounts: Fix blue-ish bg in crop dialogue



commit 3812dbc1d5731fd82075f8da6ce298fb6880a5cb
Author: Bastien Nocera <hadess hadess net>
Date:   Thu Mar 24 16:13:07 2011 +0000

    user-accounts: Fix blue-ish bg in crop dialogue
    
    The conversion to GtkStyleContext means we now use GdkRGBA,
    so we need to scale the colours between 0.0 and 1.0, not 0 and 255.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=645712

 panels/user-accounts/um-crop-area.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/panels/user-accounts/um-crop-area.c b/panels/user-accounts/um-crop-area.c
index bce39c4..94ddd0d 100644
--- a/panels/user-accounts/um-crop-area.c
+++ b/panels/user-accounts/um-crop-area.c
@@ -115,9 +115,9 @@ update_pixbufs (UmCropArea *area)
                                                      allocation.width, allocation.height);
 
                 gtk_style_context_get_background_color (context, gtk_style_context_get_state (context), &color);
-                pixel = (((gint)(color.red * 255)) << 16) |
-                        (((gint)(color.green * 255)) << 8) |
-                         ((gint)(color.blue * 255));
+                pixel = (((gint)(color.red * 1.0)) << 16) |
+                        (((gint)(color.green * 1.0)) << 8) |
+                         ((gint)(color.blue * 1.0));
                 gdk_pixbuf_fill (area->priv->pixbuf, pixel);
 
                 width = gdk_pixbuf_get_width (area->priv->browse_pixbuf);



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