Index: src/ical-code.c =================================================================== --- src/ical-code.c (revision 25178) +++ src/ical-code.c (working copy) @@ -2425,7 +2425,7 @@ * year: Year to be searched * month: Month to be searched */ -void xfical_mark_calendar(GtkCalendar *gtkcal, int year, int month) +static void xfical_mark_calendar_from_ical(GtkCalendar *gtkcal, icalcomponent *mark_ical, int year, int month) { xfical_period per; struct icaltimetype nsdate, nedate; @@ -2437,9 +2437,9 @@ gtk_calendar_freeze(gtkcal); gtk_calendar_clear_marks(gtkcal); - for (c = icalcomponent_get_first_component(ical, ICAL_VEVENT_COMPONENT); + for (c = icalcomponent_get_first_component(mark_ical, ICAL_VEVENT_COMPONENT); c != 0; - c = icalcomponent_get_next_component(ical, ICAL_VEVENT_COMPONENT)) { + c = icalcomponent_get_next_component(mark_ical, ICAL_VEVENT_COMPONENT)) { per = get_period(c); if ((per.stime.year*12+per.stime.month) <= (year*12+month) && (year*12+month) <= (per.etime.year*12+per.etime.month)) { @@ -2491,6 +2491,15 @@ gtk_calendar_thaw(gtkcal); } +void xfical_mark_calendar(GtkCalendar *gtkcal, int year, int month) +{ + gint i; + xfical_mark_calendar_from_ical(gtkcal, ical, year, month); + for (i = 0; i < g_par.foreign_count; i++) { + xfical_mark_calendar_from_ical(gtkcal, f_ical[i].ical, year, month); + } +} + void xfical_icalcomponent_archive_normal(icalcomponent *e) { icalcomponent *d;