[gnome-calendar/calendar-management] source-manager-dialog: insensitive toggle for default



commit ba55dd938e7353c53dfd15ecfc2a964e92586512
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Fri Jan 30 18:03:56 2015 -0200

    source-manager-dialog: insensitive toggle for default

 src/gcal-source-manager-dialog.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/gcal-source-manager-dialog.c b/src/gcal-source-manager-dialog.c
index c0c3996..27b110d 100644
--- a/src/gcal-source-manager-dialog.c
+++ b/src/gcal-source-manager-dialog.c
@@ -137,6 +137,9 @@ row_selected_cb (GtkListBox    *listbox,
       /* default source switch */
       gtk_switch_set_active (GTK_SWITCH (priv->default_source_switch),
                              source == gcal_manager_get_default_source (priv->manager));
+      gtk_widget_set_sensitive (priv->default_source_switch,
+                                source != gcal_manager_get_default_source (priv->manager));
+
       /* source color */
       gdk_rgba_parse (&color, e_source_selectable_get_color (E_SOURCE_SELECTABLE (extension)));
       gtk_color_chooser_set_rgba (GTK_COLOR_CHOOSER (priv->edit_color_button), &color);


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