[gdl] Do not display GdlSwitcher button when the corresponding page is hidden



commit 4eb5539fd17c1f9f9c0191a31afdd45053c389d7
Author: SÃbastien Granjoux <seb sfo free fr>
Date:   Sun Aug 5 23:02:06 2012 +0200

    Do not display GdlSwitcher button when the corresponding page is hidden
    
    When changing GdlSwitcher button style from tabs to buttons, all buttons were
    displayed even when the corresponding page was hidden.

 gdl/gdl-switcher.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gdl/gdl-switcher.c b/gdl/gdl-switcher.c
index 54dbcdf..970250e 100644
--- a/gdl/gdl-switcher.c
+++ b/gdl/gdl-switcher.c
@@ -1159,7 +1159,7 @@ gdl_switcher_set_show_buttons (GdlSwitcher *switcher, gboolean show)
     for (p = switcher->priv->buttons; p != NULL; p = p->next) {
         Button *button = p->data;
 
-        if (show)
+        if (show && gtk_widget_get_visible (button->page))
             gtk_widget_show (button->button_widget);
         else
             gtk_widget_hide (button->button_widget);



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