[gtk+] Make this code more meaningful



commit 37167ec4580225e5e0fb103ab3c816d062e20643
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue Jun 14 21:18:08 2011 -0400

    Make this code more meaningful

 tests/testgtk.c |   14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)
---
diff --git a/tests/testgtk.c b/tests/testgtk.c
index 005d575..9586169 100644
--- a/tests/testgtk.c
+++ b/tests/testgtk.c
@@ -1446,13 +1446,15 @@ make_toolbar (GtkWidget *window)
       if (make_toolbar_items[i].label == NULL)
         {
           toolitem = gtk_separator_tool_item_new ();
-          continue;
         }
-      icon  = new_pixbuf ("test.xpm", gtk_widget_get_window (window));
-      toolitem = gtk_tool_button_new (icon, make_toolbar_items[i].label);
-      gtk_tool_item_set_tooltip_text (toolitem, make_toolbar_items[i].tooltip);
-      if (make_toolbar_items[i].callback != NULL)
-        g_signal_connect (toolitem, "clicked",  make_toolbar_items[i].callback, toolbar);
+      else
+        {
+          icon  = new_pixbuf ("test.xpm", gtk_widget_get_window (window));
+          toolitem = gtk_tool_button_new (icon, make_toolbar_items[i].label);
+          gtk_tool_item_set_tooltip_text (toolitem, make_toolbar_items[i].tooltip);
+          if (make_toolbar_items[i].callback != NULL)
+            g_signal_connect (toolitem, "clicked",  make_toolbar_items[i].callback, toolbar);
+        }
       gtk_toolbar_insert (GTK_TOOLBAR (toolbar), toolitem, -1);
     }
 



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