evolution/bgo-559604-calendar-tooltip-updated.patch

58 lines
2.5 KiB
Diff

Index: calendar/gui/e-calendar-table.c
===================================================================
--- calendar/gui/e-calendar-table.c (revision 36811)
+++ calendar/gui/e-calendar-table.c (working copy)
@@ -432,7 +432,7 @@ query_tooltip_cb (GtkWidget *widget, gin
e_cal_component_free_datetime (&dtstart);
e_cal_component_free_datetime (&dtdue);
- tmp = e_calendar_view_get_attendees_status_info (new_comp);
+ tmp = e_calendar_view_get_attendees_status_info (new_comp, comp->client);
if (tmp) {
l = gtk_label_new (tmp);
gtk_misc_set_alignment (GTK_MISC (l), 0.0, 0.5);
Index: calendar/gui/e-calendar-view.c
===================================================================
--- calendar/gui/e-calendar-view.c (revision 36811)
+++ calendar/gui/e-calendar-view.c (working copy)
@@ -2137,7 +2137,7 @@ e_calendar_view_move_tip (GtkWidget *wid
* Free returned pointer with g_free.
**/
char *
-e_calendar_view_get_attendees_status_info (ECalComponent *comp)
+e_calendar_view_get_attendees_status_info (ECalComponent *comp, ECal *client)
{
struct _values {
icalparameter_partstat status;
@@ -2158,7 +2158,7 @@ e_calendar_view_get_attendees_status_inf
char *res = NULL;
int i;
- if (!comp || !e_cal_component_has_attendees (comp))
+ if (!comp || !e_cal_component_has_attendees (comp) || !itip_organizer_is_user (comp, client))
return NULL;
e_cal_component_get_attendee_list (comp, &attendees);
@@ -2354,7 +2354,7 @@ e_calendar_view_get_tooltips (ECalendarV
g_free (tmp2);
g_free (tmp1);
- tmp = e_calendar_view_get_attendees_status_info (newcomp);
+ tmp = e_calendar_view_get_attendees_status_info (newcomp, pevent->comp_data->client);
if (tmp) {
hbox = gtk_hbox_new (FALSE, 0);
gtk_box_pack_start ((GtkBox *)hbox, gtk_label_new (tmp), FALSE, FALSE, 0);
Index: calendar/gui/e-calendar-view.h
===================================================================
--- calendar/gui/e-calendar-view.h (revision 36811)
+++ calendar/gui/e-calendar-view.h (working copy)
@@ -175,7 +175,7 @@ gboolean e_calendar_view_get_tooltips (E
void e_calendar_view_move_tip (GtkWidget *widget, int x, int y);
const gchar *e_calendar_view_get_icalcomponent_summary (ECal *ecal, icalcomponent *icalcomp, gboolean *free_text);
-char *e_calendar_view_get_attendees_status_info (ECalComponent *comp);
+char *e_calendar_view_get_attendees_status_info (ECalComponent *comp, ECal *client);
void draw_curved_rectangle (cairo_t *cr,
double x0,