mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
environment: Remove toLocaleFormat and add dateUtils for date formatting
`toLocaleFormat` is now `formatDateWithCFormatString` and formatTime and formatTimeSpan are moved into dateUtils. Instead of overriding system.clearDateCaches, add a helper in dateUtils. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2827>
This commit is contained in:
parent
88eb04a42c
commit
8d48dc8c6f
8 changed files with 222 additions and 192 deletions
|
|
@ -17,7 +17,7 @@ const Layout = imports.ui.layout;
|
|||
const Main = imports.ui.main;
|
||||
const MessageTray = imports.ui.messageTray;
|
||||
const SwipeTracker = imports.ui.swipeTracker;
|
||||
|
||||
const {formatDateWithCFormatString} = imports.misc.dateUtils;
|
||||
const AuthPrompt = imports.gdm.authPrompt;
|
||||
|
||||
// The timeout before going back automatically to the lock screen (in seconds)
|
||||
|
|
@ -367,7 +367,7 @@ class UnlockDialogClock extends St.BoxLayout {
|
|||
/* Translators: This is a time format for a date in
|
||||
long format */
|
||||
let dateFormat = Shell.util_translate_time_string(N_('%A %B %-d'));
|
||||
this._date.text = date.toLocaleFormat(dateFormat);
|
||||
this._date.text = formatDateWithCFormatString(date, dateFormat);
|
||||
}
|
||||
|
||||
_updateHint() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue