mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 23:37:35 +00:00
LibJS+LibLocale: Port Intl.DateTimeFormat to String
This commit is contained in:
parent
970e9df245
commit
b2097f4059
8 changed files with 223 additions and 197 deletions
|
@ -135,8 +135,8 @@ void TimeZoneSettingsWidget::set_time_zone_location()
|
|||
auto locale = Locale::default_locale();
|
||||
auto now = AK::Time::now_realtime();
|
||||
|
||||
auto name = Locale::format_time_zone(locale, m_time_zone, Locale::CalendarPatternStyle::Long, now);
|
||||
auto offset = Locale::format_time_zone(locale, m_time_zone, Locale::CalendarPatternStyle::LongOffset, now);
|
||||
auto name = Locale::format_time_zone(locale, m_time_zone, Locale::CalendarPatternStyle::Long, now).release_value_but_fixme_should_propagate_errors();
|
||||
auto offset = Locale::format_time_zone(locale, m_time_zone, Locale::CalendarPatternStyle::LongOffset, now).release_value_but_fixme_should_propagate_errors();
|
||||
|
||||
m_time_zone_text = DeprecatedString::formatted("{}\n({})", name, offset);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue