diff options
-rw-r--r-- | widgets/table/ChangeLog | 7 | ||||
-rw-r--r-- | widgets/table/e-table-header-utils.c | 5 |
2 files changed, 9 insertions, 3 deletions
diff --git a/widgets/table/ChangeLog b/widgets/table/ChangeLog index a329658289..c9b68fd40b 100644 --- a/widgets/table/ChangeLog +++ b/widgets/table/ChangeLog @@ -1,3 +1,10 @@ +2006-06-08 Carlos Garcia Campos <carlosgc@gnome.org> + + ** Fixes bug #343764 + * e-table-header-utils.c: (e_table_header_draw_button): + Ensure g_label points to the right widget before accessing to its + style. + 2006-06-05 Hiroyuki Ikezoe <poincare@ikezoe.net> * Makefile.am: Remove extra tabs. Fixes #343734. diff --git a/widgets/table/e-table-header-utils.c b/widgets/table/e-table-header-utils.c index 8a1831bd49..8d452467c6 100644 --- a/widgets/table/e-table-header-utils.c +++ b/widgets/table/e-table-header-utils.c @@ -303,8 +303,6 @@ e_table_draw_elided_string (GdkDrawable *drawable, GdkGC *gc, GtkWidget *widget, } } -static GtkWidget *g_label; - /** * e_table_header_draw_button: * @drawable: Destination drawable. @@ -335,6 +333,7 @@ e_table_header_draw_button (GdkDrawable *drawable, ETableCol *ecol, int inner_width, inner_height; GdkGC *gc; PangoLayout *layout; + static GtkWidget *g_label = NULL; g_return_if_fail (drawable != NULL); g_return_if_fail (ecol != NULL); @@ -347,10 +346,10 @@ e_table_header_draw_button (GdkDrawable *drawable, ETableCol *ecol, if (g_label == NULL) { GtkWidget *button = gtk_button_new_with_label("Hi"); GtkWidget *window = gtk_window_new(GTK_WINDOW_TOPLEVEL); - g_label = GTK_BIN(button)->child; gtk_container_add (GTK_CONTAINER (window), button); gtk_widget_ensure_style (window); gtk_widget_ensure_style (button); + g_label = GTK_BIN(button)->child; gtk_widget_ensure_style (g_label); } |