[vinagre] Read a list of groups from the plugins, instead of just one.



commit e2b097a98d091435be5c6a2693fd73912f2fbbdd
Author: Jonh Wendell <jwendell gnome org>
Date:   Tue Aug 11 15:22:45 2009 -0300

    Read a list of groups from the plugins, instead of just one.

 vinagre/vinagre-main.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/vinagre/vinagre-main.c b/vinagre/vinagre-main.c
index ffb0fe6..e0b6e49 100644
--- a/vinagre/vinagre-main.c
+++ b/vinagre/vinagre-main.c
@@ -173,14 +173,16 @@ int main (int argc, char **argv) {
   for (l = plugins; l; l = l->next)
     {
       GOptionGroup      *group;
+      GSList            *groups, *l2;
       VinagrePluginInfo *info = VINAGRE_PLUGIN_INFO (l->data);
 
       if (!vinagre_plugin_info_is_active (info))
 	continue;
 
-      group = vinagre_plugin_get_context_group (info->plugin);
-      if (group)
-	g_option_context_add_group (context, group);
+      groups = vinagre_plugin_get_context_groups (info->plugin);
+      for (l2 = groups; l2; l2 = l2->next)
+	g_option_context_add_group (context, (GOptionGroup *)l2->data);
+      g_slist_free (groups);
     }
 
   g_option_context_parse (context, &argc, &argv, &error);



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