[gnome-calendar] quick-add-popover: adjust end date properly



commit 2ac228a9b8f4ff1e5ae7b05eee211d40dfe9a42f
Author: fosero <fosero users noreply github com>
Date:   Fri Mar 11 13:10:17 2016 +0100

    quick-add-popover: adjust end date properly
    
    Subtracting 1 from the first day of the month leads to an invalid date
    being shown: use a proper function to adjust the date.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=763015

 src/gcal-quick-add-popover.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/gcal-quick-add-popover.c b/src/gcal-quick-add-popover.c
index 2fb46be..3296ed9 100644
--- a/src/gcal-quick-add-popover.c
+++ b/src/gcal-quick-add-popover.c
@@ -231,7 +231,7 @@ update_header (GcalQuickAddPopover *self)
       dtend = datetime_to_icaltime (self->date_end);
 
       if (dtend->is_date)
-        dtend->day--;
+        icaltime_adjust (dtend, -1, 0, 0, 0);
 
       /* Translators:
        * this is the format string for representing a date consisting of a month name


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