Detect system timezone from Javascript Internationalization API
Categories
(Calendar :: Internal Components, defect, P2)
Tracking
(thunderbird_esr91 wontfix, thunderbird93 wontfix)
People
(Reporter: Fallen, Assigned: mschroeder)
References
Details
Attachments
(1 file)
With the Intl API its possible to get the system timezone in one line of code. This would mean we can get rid of the whole guessSystemTimezone. Here is how: Intl.DateTimeFormat().resolvedOptions().timeZone Requires bug 895737 and maybe bug 837961 fixed.
Updated•8 years ago
|
Comment 1•6 years ago
|
||
What is guessSystemTimezone? I can't find in the source. Is there a chance that this is already fixed?
Assignee | ||
Comment 2•6 years ago
|
||
Zibi, here is the function "guessSystemTimezone" in Lightning: https://dxr.mozilla.org/comm-central/source/calendar/base/src/calTimezoneService.js#299
Reporter | ||
Comment 3•6 years ago
|
||
Yes, it does seem Intl.DateTimeFormat().resolvedOptions().timeZone gives the most current timezone, this bug could probably be fixed in Lightning now. Of course having a way to detect if the timezone changes would be favorable, I'm not sure if that is possible yet.
Comment 4•6 years ago
|
||
I'm using TB 52.5 under Windows 10 and the timezone is still not automatically changed using the system timezone. Do you plan to implement it shortly? Thanks!
Comment 5•6 years ago
|
||
This is still blocked by bug 895737 (effectively by bug 1343826; I just checked, a runtime change of the system timezone is still not detected). That said, once that is fixed, we're happy to consider this bug for the then upcoming esr version.
Comment 6•4 years ago
|
||
Hi, Can I work on this? I am new.
Updated•2 years ago
|
Assignee | ||
Comment 8•2 years ago
|
||
Updated•2 years ago
|
Assignee | ||
Comment 9•2 years ago
|
||
Removing the dependency on bug 1343826 to move the topic "system timezone change" to bug 1606357.
Assignee | ||
Updated•2 years ago
|
Comment 10•2 years ago
|
||
Very nice indeed, thx Martin!
Comment 11•2 years ago
|
||
Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/4315d972034a
Detect system default timezone from JavaScript Internationalization API. r=darktrojan
Comment 13•1 year ago
|
||
As Bug 1684021 appears to have messed up the Brazilian timezones DST again, would uplift of this to ESR be a suitable fix?
Assignee | ||
Comment 14•1 year ago
|
||
(In reply to Matt from comment #13)
As Bug 1684021 appears to have messed up the Brazilian timezones DST again, would uplift of this to ESR be a suitable fix?
This is only relevant for determining the system timezone at first start or when no timezone has been set in Thunderbird preferences for calendar. So, this is not a fix for the problem you described.
Description
•