[gtranslator] Do not create the tab label twice



commit b64e0fcdd9e3830b79f1c8de26fffce113bd9bd3
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Wed May 4 13:58:56 2011 +0200

    Do not create the tab label twice

 src/gtr-notebook.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/gtr-notebook.c b/src/gtr-notebook.c
index 704ed07..4487b93 100644
--- a/src/gtr-notebook.c
+++ b/src/gtr-notebook.c
@@ -74,7 +74,8 @@ remove_tab_label (GtrNotebook *nb,
 {
   GtkWidget *tab_label;
 
-  tab_label = gtr_tab_label_new (tab);
+  tab_label = g_object_get_data (G_OBJECT (tab), "tab-label");
+  g_return_if_fail (tab_label != NULL);
 
   g_signal_handlers_disconnect_by_func (tab_label,
                                         G_CALLBACK (close_button_clicked_cb),



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