bitfireAT/ical4android

Always prefer Android time zone names to ical4j time zone names

rfc2822 opened this issue · 0 comments

We need a solution for bitfireAT/davx5-ose#133 until #56 is finished (and on Android level <26). Problem:

  1. Event with time zone Europe/Kiev is created locally in Android.
  2. ical4android feeds the event to ical4j and understands Europe/Kiev as an alias for the the newer Europe/Kyiv.
  3. So, the exported iCalendar file has DTSTART;TZID=Europe/Kyiv:…
  4. When the iCalendar is imported later, DAVx5 sees that Android doesn't understand Europe/Kyiv and rewrites it to the current system time zone.

I think the straightest solution is that when a time zone is present in both ical4j and Android, but with different names (like Europe/Kiev and Europe/Kyiv), the Android name should always be preferred (because Android sometimes has to be able to process the time zone information, too) and also exported (so that it can be imported again without information loss).

This is also related to AndroidEvent.androidifyTimeZone, which must never return a time zone Android doesn't know.