[totem] grilo: Store the recent and channels buttons



commit 56c3e63c8c04220e2d32968dbb140a105c5a3fd1
Author: Bastien Nocera <hadess hadess net>
Date:   Fri Jan 17 15:03:13 2014 +0100

    grilo: Store the recent and channels buttons

 src/plugins/grilo/totem-grilo.c |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/src/plugins/grilo/totem-grilo.c b/src/plugins/grilo/totem-grilo.c
index cdebac1..69657f7 100644
--- a/src/plugins/grilo/totem-grilo.c
+++ b/src/plugins/grilo/totem-grilo.c
@@ -100,6 +100,7 @@ typedef struct {
        GSimpleAction *select_all_action;
        GSimpleAction *select_none_action;
        GtkWidget *switcher;
+       GtkWidget *recent, *channels;
 
        /* Browser widgets */
        GtkWidget *browser;
@@ -1334,12 +1335,13 @@ setup_source_switcher (TotemGriloPlugin *self)
 
        self->priv->switcher = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
 
-       button1 = create_switcher_button (self, _("Recent"), "recent");
-       gtk_container_add (GTK_CONTAINER (self->priv->switcher), button1);
+       self->priv->recent = create_switcher_button (self, _("Recent"), "recent");
+       gtk_container_add (GTK_CONTAINER (self->priv->switcher), self->priv->recent);
 
-       button2 = create_switcher_button (self, _("Channels"), "channels");
-       gtk_radio_button_join_group (GTK_RADIO_BUTTON (button2), GTK_RADIO_BUTTON (button1));
-       gtk_container_add (GTK_CONTAINER (self->priv->switcher), button2);
+       self->priv->channels = create_switcher_button (self, _("Channels"), "channels");
+       gtk_radio_button_join_group (GTK_RADIO_BUTTON (self->priv->channels),
+                                    GTK_RADIO_BUTTON (self->priv->recent));
+       gtk_container_add (GTK_CONTAINER (self->priv->switcher), self->priv->channels);
 
        context = gtk_widget_get_style_context (self->priv->switcher);
        gtk_style_context_add_class (context, "stack-switcher");


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