mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 09:04:13 +00:00
Merge 5df4c5d940
into 283ecfe8b2
This commit is contained in:
commit
3ed1e5c1dc
1 changed files with 4 additions and 5 deletions
|
@ -1462,7 +1462,7 @@ static int uninitialisedOffset = 100000;
|
|||
* Try to get timezone from windows system call.
|
||||
*/
|
||||
{
|
||||
TIME_ZONE_INFORMATION tz;
|
||||
DYNAMIC_TIME_ZONE_INFORMATION tz;
|
||||
DWORD dst;
|
||||
wchar_t *tzName;
|
||||
|
||||
|
@ -1470,15 +1470,14 @@ static int uninitialisedOffset = 100000;
|
|||
// Get time zone name for US locale as expected by ICU method below
|
||||
LANGID origLangID = GetThreadUILanguage();
|
||||
SetThreadUILanguage(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US));
|
||||
dst = GetTimeZoneInformation(&tz);
|
||||
dst = GetDynamicTimeZoneInformation(&tz);
|
||||
SetThreadUILanguage(origLangID);
|
||||
|
||||
// Only tz.StandardName time zone conversions are supported, as
|
||||
// the Zone-Tzid table lacks all daylight time conversions:
|
||||
// The Zone-Tzid table lacks all daylight time conversions:
|
||||
// e.g. 'W. Europe Daylight Time' <-> 'Europe/Berlin' is not listed.
|
||||
//
|
||||
// See: https://unicode-org.github.io/cldr-staging/charts/latest/supplemental/zone_tzid.html
|
||||
tzName = tz.StandardName;
|
||||
tzName = tz.TimeZoneKeyName;
|
||||
#else
|
||||
dst = GetTimeZoneInformation(&tz);
|
||||
|
||||
|
|
Loading…
Reference in a new issue