[Galago-commits] r2950 - in trunk/notification-daemon: . src/themes/standard

galago-commits at freedesktop.org galago-commits at freedesktop.org
Mon Nov 13 00:51:15 PST 2006


Author: chipx86
Date: 2006-11-13 00:51:10 -0800 (Mon, 13 Nov 2006)
New Revision: 2950

Modified:
   trunk/notification-daemon/ChangeLog
   trunk/notification-daemon/src/themes/standard/theme.c
Log:
- Fix fill_background() to use the allocated width and height, rather than the stored width and height. This fixes a problem where the widget was being painted grey.
- Use fill_background() for both the window and the pie progress thing.


Modified: trunk/notification-daemon/ChangeLog
===================================================================
--- trunk/notification-daemon/ChangeLog	2006-11-10 02:04:27 UTC (rev 2949)
+++ trunk/notification-daemon/ChangeLog	2006-11-13 08:51:10 UTC (rev 2950)
@@ -1,3 +1,11 @@
+Mon Nov 13 00:49:42 PST 2006  Christian Hammond <chipx86 at chipx86.com>
+
+	* src/themes/standard/theme.c:
+	  - Fix fill_background() to use the allocated width and height, rather
+	    than the stored width and height. This fixes a problem where the
+	    widget was being painted grey.
+	  - Use fill_background() for both the window and the pie progress thing.
+
 Thu Nov 09 18:03:31 PST 2006  Christian Hammond <chipx86 at chipx86.com>
 
 	* src/themes/standard/theme.c:

Modified: trunk/notification-daemon/src/themes/standard/theme.c
===================================================================
--- trunk/notification-daemon/src/themes/standard/theme.c	2006-11-10 02:04:27 UTC (rev 2949)
+++ trunk/notification-daemon/src/themes/standard/theme.c	2006-11-13 08:51:10 UTC (rev 2950)
@@ -70,13 +70,15 @@
 #define DEFAULT_ARROW_WIDTH   28
 
 static void
-fill_background(GtkWidget *win, WindowData *windata)
+fill_background(GtkWidget *widget, WindowData *windata)
 {
-	GtkStyle *style = gtk_widget_get_style(win);
-	GdkGC *gc = style->base_gc[GTK_STATE_NORMAL];
+	GtkStyle *style = gtk_widget_get_style(windata->win);
 
-	gdk_draw_rectangle(GDK_DRAWABLE(win->window), gc, TRUE,
-					   0, 0, windata->width, windata->height);
+	gdk_draw_rectangle(GDK_DRAWABLE(widget->window),
+					   style->base_gc[GTK_STATE_NORMAL], TRUE,
+					   0, 0,
+					   widget->allocation.width,
+					   widget->allocation.height);
 }
 
 static void
@@ -710,10 +712,8 @@
 					WindowData *windata)
 {
 	GtkStyle *style = gtk_widget_get_style(windata->win);
-	GdkGC *bg_gc = style->base_gc[GTK_STATE_NORMAL];
 
-	gdk_draw_rectangle(GDK_DRAWABLE(pie->window), bg_gc, TRUE,
-					   0, 0, pie->allocation.width, pie->allocation.height);
+	fill_background(pie, windata);
 
 	if (windata->timeout > 0)
 	{



More information about the galago-commits mailing list