summaryrefslogtreecommitdiff
path: root/offapi
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2019-06-19 23:03:49 +0200
committerEike Rathke <erack@redhat.com>2019-06-20 11:27:20 +0200
commita9c02d543987a0c05beda19905ccd6fb4263b592 (patch)
tree9a9d974383787f937196a974446402bc9fe04068 /offapi
parent79e6e4eef098d841eb639f21a905b10bc5db7d56 (diff)
Resolves: tdf#92503 introduce TimeZone to calendar loading and default to UTC
Without that, the system's time zone was used which on DST transition dates leads to non-existent times when switching to/from DST. As the calendar use and number parser/formatter nor conversions or calculations are time zone aware, using not DST afflicted UTC is the better choice. Change-Id: I3303c6620d8c4b9d081555c8293954fb1bd67895 Reviewed-on: https://gerrit.libreoffice.org/74386 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins (cherry picked from commit 942de6a01ba990e5f3bc55ce4ab3737a03f67f39) Reviewed-on: https://gerrit.libreoffice.org/74399
Diffstat (limited to 'offapi')
-rw-r--r--offapi/com/sun/star/i18n/XCalendar4.idl24
1 files changed, 24 insertions, 0 deletions
diff --git a/offapi/com/sun/star/i18n/XCalendar4.idl b/offapi/com/sun/star/i18n/XCalendar4.idl
index 1303dc0aed11..94686b4a0031 100644
--- a/offapi/com/sun/star/i18n/XCalendar4.idl
+++ b/offapi/com/sun/star/i18n/XCalendar4.idl
@@ -49,6 +49,30 @@ interface XCalendar4 : com::sun::star::i18n::XCalendar3
*/
double getLocalDateTime();
+ /** Load the default calendar for the given locale with a given time zone.
+
+ @param TimeZone
+ If empty, the system's time zone is used.
+ Else specified as "Region/City" name like "Europe/Berlin",
+ or a custom time zone ID such as "UTC" or "GMT-8:00".
+
+ @since LibreOffice 6.3
+ */
+ void loadDefaultCalendarTZ( [in] ::com::sun::star::lang::Locale rLocale, [in] string TimeZone );
+
+ /** Load a specific calendar for the given locale with a given time zone.
+
+ @param TimeZone
+ If empty, the system's time zone is used.
+ Else specified as "Region/City" name like "Europe/Berlin",
+ or a custom time zone ID such as "UTC" or "GMT-8:00".
+
+ @since LibreOffice 6.3
+ */
+ void loadCalendarTZ( [in] string uniqueID,
+ [in] ::com::sun::star::lang::Locale rLocale,
+ [in] string TimeZone );
+
};
}; }; }; };