[evolution/gnome-3-20] Bug 767334 - Unable to open attachments when I am not the organiser
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/gnome-3-20] Bug 767334 - Unable to open attachments when I am not the organiser
- Date: Mon, 13 Jun 2016 12:22:29 +0000 (UTC)
commit e746cf9763623bab6f059b403372108f676b752b
Author: Milan Crha <mcrha redhat com>
Date: Mon Jun 13 14:20:01 2016 +0200
Bug 767334 - Unable to open attachments when I am not the organiser
calendar/gui/e-comp-editor-page-attachments.c | 20 ++++++++++++++++++--
1 files changed, 18 insertions(+), 2 deletions(-)
---
diff --git a/calendar/gui/e-comp-editor-page-attachments.c b/calendar/gui/e-comp-editor-page-attachments.c
index 4b6276f..776f3a2 100644
--- a/calendar/gui/e-comp-editor-page-attachments.c
+++ b/calendar/gui/e-comp-editor-page-attachments.c
@@ -241,8 +241,8 @@ ecep_attachments_sensitize_widgets (ECompEditorPage *page,
page_attachments = E_COMP_EDITOR_PAGE_ATTACHMENTS (page);
- gtk_widget_set_sensitive (page_attachments->priv->controls_container, !force_insensitive &&
is_organizer);
- gtk_widget_set_sensitive (page_attachments->priv->notebook, !force_insensitive && is_organizer);
+ gtk_widget_set_sensitive (page_attachments->priv->controls_container, !force_insensitive);
+ gtk_widget_set_sensitive (page_attachments->priv->notebook, !force_insensitive);
action = e_comp_editor_get_action (comp_editor, "attachments-attach");
gtk_action_set_sensitive (action, !force_insensitive && is_organizer);
@@ -664,6 +664,7 @@ static void
ecep_attachments_constructed (GObject *object)
{
ECompEditorPageAttachments *page_attachments;
+ ECompEditor *comp_editor;
GSettings *settings;
GtkSizeGroup *size_group;
GtkWidget *container;
@@ -831,6 +832,21 @@ ecep_attachments_constructed (GObject *object)
g_clear_object (&settings);
ecep_attachments_setup_ui (page_attachments);
+
+ comp_editor = e_comp_editor_page_ref_editor (E_COMP_EDITOR_PAGE (page_attachments));
+ action = e_comp_editor_get_action (comp_editor, "attachments-attach");
+
+ e_binding_bind_property (
+ action, "sensitive",
+ e_attachment_view_get_action (E_ATTACHMENT_VIEW (page_attachments->priv->icon_view), "add"),
"sensitive",
+ G_BINDING_SYNC_CREATE);
+
+ e_binding_bind_property (
+ action, "sensitive",
+ e_attachment_view_get_action (E_ATTACHMENT_VIEW (page_attachments->priv->tree_view), "add"),
"sensitive",
+ G_BINDING_SYNC_CREATE);
+
+ g_clear_object (&comp_editor);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]