diff --git a/autotests/data/Compat-libical3/Todos.ics b/autotests/data/Compat-libical3/Todos.ics new file mode 100644 --- /dev/null +++ b/autotests/data/Compat-libical3/Todos.ics @@ -0,0 +1,29 @@ +BEGIN:VCALENDAR +VERSION:2.0 +X-WR-CALNAME:YES2 +PRODID:-//Hand crafted//iCal 1.5//EN +BEGIN:VTIMEZONE +TZID:Europe/Paris +BEGIN:STANDARD +TZOFFSETTO:0100 +END:STANDARD +BEGIN:DAYLIGHT +TZOFFSETTO:0200 +END:DAYLIGHT +END:VTIMEZONE +BEGIN:VTODO +DTSTART;VALUE=DATE:20040104 +DTEND;VALUE=DATE:20040105 +SUMMARY:Date only todo with start and end +UID:76338FE5-873F-11D8-92F9-0003939BE42C +SEQUENCE:2 +END:VTODO +BEGIN:VTODO +DTSTART;VALUE=DATE:20040104 +SUMMARY:Date only todo with due date +UID:7633834F-873F-11D8-92F9-0003939BE42C +SEQUENCE:4 +PRIORITY:1 +DUE;VALUE=DATE:20170730 +END:VTODO +END:VCALENDAR diff --git a/autotests/data/Compat-libical3/Todos.ics.ical.ref b/autotests/data/Compat-libical3/Todos.ics.ical.ref new file mode 100644 --- /dev/null +++ b/autotests/data/Compat-libical3/Todos.ics.ical.ref @@ -0,0 +1,28 @@ +BEGIN:VCALENDAR +PRODID:-//K Desktop Environment//NONSGML libkcal 4.3//EN +VERSION:2.0 +X-KDE-ICAL-IMPLEMENTATION-VERSION:1.0 +X-WR-CALNAME:YES2 +BEGIN:VTODO +DTSTAMP:20171125T103935Z +CREATED:20171125T103935Z +UID:76338FE5-873F-11D8-92F9-0003939BE42C +SEQUENCE:2 +LAST-MODIFIED:20171125T103935Z +SUMMARY:Date only todo with start and end +DTSTART;VALUE=DATE:20040104 +PERCENT-COMPLETE:0 +END:VTODO +BEGIN:VTODO +DTSTAMP:20171125T103935Z +CREATED:20171125T103935Z +UID:7633834F-873F-11D8-92F9-0003939BE42C +SEQUENCE:4 +LAST-MODIFIED:20171125T103935Z +SUMMARY:Date only todo with due date +PRIORITY:1 +DUE;VALUE=DATE:20170730 +DTSTART;VALUE=DATE:20040104 +PERCENT-COMPLETE:0 +END:VTODO +END:VCALENDAR diff --git a/autotests/data/Compat/Todos.ics b/autotests/data/Compat/Todos.ics new file mode 100644 --- /dev/null +++ b/autotests/data/Compat/Todos.ics @@ -0,0 +1,29 @@ +BEGIN:VCALENDAR +VERSION:2.0 +X-WR-CALNAME:YES2 +PRODID:-//Hand crafted//iCal 1.5//EN +BEGIN:VTIMEZONE +TZID:Europe/Paris +BEGIN:STANDARD +TZOFFSETTO:0100 +END:STANDARD +BEGIN:DAYLIGHT +TZOFFSETTO:0200 +END:DAYLIGHT +END:VTIMEZONE +BEGIN:VTODO +DTSTART;VALUE=DATE:20040104 +DTEND;VALUE=DATE:20040105 +SUMMARY:Date only todo with start and end +UID:76338FE5-873F-11D8-92F9-0003939BE42C +SEQUENCE:2 +END:VTODO +BEGIN:VTODO +DTSTART;VALUE=DATE:20040104 +SUMMARY:Date only todo with due date +UID:7633834F-873F-11D8-92F9-0003939BE42C +SEQUENCE:4 +PRIORITY:1 +DUE;VALUE=DATE:20170730 +END:VTODO +END:VCALENDAR diff --git a/autotests/data/Compat/Todos.ics.ical.ref b/autotests/data/Compat/Todos.ics.ical.ref new file mode 100644 --- /dev/null +++ b/autotests/data/Compat/Todos.ics.ical.ref @@ -0,0 +1,28 @@ +BEGIN:VCALENDAR +PRODID:-//K Desktop Environment//NONSGML libkcal 4.3//EN +VERSION:2.0 +X-KDE-ICAL-IMPLEMENTATION-VERSION:1.0 +X-WR-CALNAME:YES2 +BEGIN:VTODO +DTSTAMP:20171125T103935Z +CREATED:20171125T103935Z +UID:76338FE5-873F-11D8-92F9-0003939BE42C +SEQUENCE:2 +LAST-MODIFIED:20171125T103935Z +SUMMARY:Date only todo with start and end +DTSTART;VALUE=DATE:20040104 +PERCENT-COMPLETE:0 +END:VTODO +BEGIN:VTODO +DTSTAMP:20171125T103935Z +CREATED:20171125T103935Z +UID:7633834F-873F-11D8-92F9-0003939BE42C +SEQUENCE:4 +LAST-MODIFIED:20171125T103935Z +SUMMARY:Date only todo with due date +PRIORITY:1 +DUE;VALUE=DATE:20170730 +DTSTART;VALUE=DATE:20040104 +PERCENT-COMPLETE:0 +END:VTODO +END:VCALENDAR diff --git a/src/icalformat_p.cpp b/src/icalformat_p.cpp --- a/src/icalformat_p.cpp +++ b/src/icalformat_p.cpp @@ -1187,7 +1187,7 @@ bool allDay = false; QDateTime kdt = readICalDateTimeProperty(p, tzlist, false, &allDay); todo->setDtDue(kdt, true); - todo->setAllDay(false); + todo->setAllDay(allDay); break; } case ICAL_COMPLETED_PROPERTY: // completion date/time