[evolution] I#190 - [Meeting editor] Show email addresses when needed ][



commit 55d34104ac8541547c2ea251470efa9966d7697e
Author: Milan Crha <mcrha redhat com>
Date:   Mon Oct 29 11:29:45 2018 +0100

    I#190 - [Meeting editor] Show email addresses when needed ][
    
    Missed an auto-completed case, when not picked from the name selector.
    
    Closes https://gitlab.gnome.org/GNOME/evolution/issues/190

 src/calendar/gui/e-meeting-list-view.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)
---
diff --git a/src/calendar/gui/e-meeting-list-view.c b/src/calendar/gui/e-meeting-list-view.c
index 6ba763f78e..5bd9fb2eb0 100644
--- a/src/calendar/gui/e-meeting-list-view.c
+++ b/src/calendar/gui/e-meeting-list-view.c
@@ -411,6 +411,7 @@ attendee_edited_cb (GtkCellRenderer *renderer,
                        }
                } else {
                        gboolean address_changed = FALSE;
+                       gboolean show_address = FALSE;
                        EMeetingAttendee *attendee;
                        EDestination *destination;
 
@@ -448,9 +449,20 @@ attendee_edited_cb (GtkCellRenderer *renderer,
                                                e_meeting_attendee_set_fburi (attendee, fburi);
                                        else
                                                g_free (fburi);
+
+                                       if (!e_contact_get (contact, E_CONTACT_IS_LIST)) {
+                                               GList *email_list;
+
+                                               email_list = e_contact_get (contact, E_CONTACT_EMAIL);
+                                               show_address = email_list && email_list->next;
+                                               g_list_free_full (email_list, g_free);
+                                       }
                                }
                        }
 
+                       e_meeting_attendee_set_show_address (attendee, show_address ||
+                               e_meeting_attendee_get_show_address (attendee));
+
                        e_meeting_list_view_add_attendee_to_name_selector (E_MEETING_LIST_VIEW (view), 
attendee);
 
                        if (address_changed)


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