[gnome-builder] view-stack: desensitize buttons for initial state
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] view-stack: desensitize buttons for initial state
- Date: Sat, 19 Sep 2015 09:24:15 +0000 (UTC)
commit daf669d12b8716b5f4ff46891d158cc806587f0f
Author: Christian Hergert <christian hergert me>
Date: Sat Sep 19 02:23:48 2015 -0700
view-stack: desensitize buttons for initial state
Until we've opened something, keep these buttons insensitive.
src/views/gb-view-stack.c | 30 +++++++++++++++---------------
1 files changed, 15 insertions(+), 15 deletions(-)
---
diff --git a/src/views/gb-view-stack.c b/src/views/gb-view-stack.c
index 15dc214..a2409e9 100644
--- a/src/views/gb-view-stack.c
+++ b/src/views/gb-view-stack.c
@@ -461,6 +461,21 @@ gb_view_stack_constructed (GObject *object)
G_CONNECT_SWAPPED);
gb_view_stack_actions_init (self);
+
+ /*
+ * FIXME:
+ *
+ * https://bugzilla.gnome.org/show_bug.cgi?id=747060
+ *
+ * Setting sensitive in the template is getting changed out from under us.
+ * Likely due to the popover item being set (conflation of having a popover
+ * vs wanting sensitivity). So we will just override it here.
+ *
+ * Last tested Gtk+ was 3.17.
+ */
+ gtk_widget_set_sensitive (GTK_WIDGET (self->close_button), FALSE);
+ gtk_widget_set_sensitive (GTK_WIDGET (self->views_button), FALSE);
+ gtk_widget_set_sensitive (GTK_WIDGET (self->document_button), FALSE);
}
static void
@@ -607,21 +622,6 @@ gb_view_stack_init (GbViewStack *self)
self,
G_CONNECT_SWAPPED);
- /*
- * FIXME:
- *
- * https://bugzilla.gnome.org/show_bug.cgi?id=747060
- *
- * Setting sensitive in the template is getting changed out from under us.
- * Likely due to the popover item being set (conflation of having a popover
- * vs wanting sensitivity). So we will just override it here.
- *
- * Last tested Gtk+ was 3.16.0.
- */
- g_object_set (self->document_button,
- "sensitive", FALSE,
- NULL);
-
gb_widget_set_context_handler (self, gb_view_stack_context_handler);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]