[vinagre] Fixed showing plugin specific widgets in connect dialog.



commit 7a0a0bc578b3f3fe7a35d024f24828eb51a678ed
Author: Jonh Wendell <jwendell gnome org>
Date:   Thu Jul 30 16:28:23 2009 -0300

    Fixed showing plugin specific widgets in connect dialog.

 data/vinagre.ui           |    2 +-
 vinagre/vinagre-connect.c |    8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/data/vinagre.ui b/data/vinagre.ui
index 0fb7dad..a1f2a9a 100644
--- a/data/vinagre.ui
+++ b/data/vinagre.ui
@@ -204,7 +204,7 @@
           </packing>
         </child>
         <child>
-          <object class="GtkVBox" id="plugin_options_vbox">
+          <object class="GtkVBox" id="plugin_options_connect_vbox">
             <property name="visible">True</property>
             <property name="orientation">vertical</property>
             <child>
diff --git a/vinagre/vinagre-connect.c b/vinagre/vinagre-connect.c
index 0c3b9ec..e2a2483 100644
--- a/vinagre/vinagre-connect.c
+++ b/vinagre/vinagre-connect.c
@@ -110,8 +110,7 @@ protocol_combo_changed (GtkComboBox *combo, VinagreConnectDialog *dialog)
   if (options)
     {
       gtk_box_pack_start (GTK_BOX (dialog->plugin_box), options, TRUE, TRUE, 0);
-      g_object_unref (options);
-      gtk_widget_show (dialog->plugin_box);
+      gtk_widget_show_all (dialog->plugin_box);
     }
   else
     gtk_widget_hide (dialog->plugin_box);
@@ -163,7 +162,8 @@ setup_protocol (VinagreConnectDialog *dialog)
         selected = i;
 
       g_strfreev (description);
-      g_object_unref (widget);
+      if (widget)
+	g_object_unref (widget);
       i++;
     }
 
@@ -373,7 +373,7 @@ VinagreConnection *vinagre_connect (VinagreWindow *window)
   dialog.host_entry  = GTK_WIDGET (gtk_builder_get_object (dialog.xml, "host_entry"));
   dialog.find_button = GTK_WIDGET (gtk_builder_get_object (dialog.xml, "find_button"));
   dialog.fullscreen_check = GTK_WIDGET (gtk_builder_get_object (dialog.xml, "fullscreen_check"));
-  dialog.plugin_box = GTK_WIDGET (gtk_builder_get_object (dialog.xml, "plugin_options_vbox"));
+  dialog.plugin_box = GTK_WIDGET (gtk_builder_get_object (dialog.xml, "plugin_options_connect_vbox"));
 
   setup_protocol (&dialog);
   setup_combo (dialog.host_entry);



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