[gnome-games] aisleriot: Fix the statusbar-related GSEAL issues
- From: Thomas Hindoe Paaboel Andersen <thomashpa src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-games] aisleriot: Fix the statusbar-related GSEAL issues
- Date: Tue, 6 Oct 2009 21:53:28 +0000 (UTC)
commit 7436c9e0f02797e0b1f2c5429266668baf00fd81
Author: Thomas Hindoe Paaboel Andersen <phomes gmail com>
Date: Tue Oct 6 23:52:32 2009 +0200
aisleriot: Fix the statusbar-related GSEAL issues
Bug #586731
aisleriot/window.c | 18 ++++++++++++------
1 files changed, 12 insertions(+), 6 deletions(-)
---
diff --git a/aisleriot/window.c b/aisleriot/window.c
index e558e40..720069d 100644
--- a/aisleriot/window.c
+++ b/aisleriot/window.c
@@ -2492,7 +2492,9 @@ aisleriot_window_init (AisleriotWindow *window)
#else
const char *env;
GtkStatusbar *statusbar;
- GtkWidget *statusbar_hbox,*label, *time_box;
+ GtkWidget *statusbar_hbox, *statusbar_label, *label, *time_box;
+ GtkContainer *statusbar_frame;
+ GList *list;
#endif
g_assert (G_N_ELEMENTS (names) == LAST_ACTION);
@@ -2580,11 +2582,15 @@ aisleriot_window_init (AisleriotWindow *window)
* which we put in the statusbar's frame instead.
*/
statusbar_hbox = gtk_hbox_new (FALSE, 24);
- g_object_ref (statusbar->label);
- gtk_container_remove (GTK_CONTAINER (statusbar->frame), statusbar->label);
- gtk_box_pack_start (GTK_BOX (statusbar_hbox), statusbar->label, TRUE, TRUE, 0);
- g_object_unref (statusbar->label);
- gtk_container_add (GTK_CONTAINER (statusbar->frame), statusbar_hbox);
+ list = gtk_container_get_children (GTK_CONTAINER (statusbar));
+ statusbar_frame = GTK_CONTAINER (list->data);
+ g_list_free (list);
+ statusbar_label = gtk_bin_get_child (GTK_BIN (statusbar_frame));
+ g_object_ref (statusbar_label);
+ gtk_container_remove (statusbar_frame, statusbar_label);
+ gtk_box_pack_start (GTK_BOX (statusbar_hbox), statusbar_label, TRUE, TRUE, 0);
+ g_object_unref (statusbar_label);
+ gtk_container_add (statusbar_frame, statusbar_hbox);
gtk_widget_show (statusbar_hbox);
/* Score */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]