shell/util: Use gtk4 for week-start fallback

If langinfo isn't available, we determine the week start via
a "magic" string translation from GTK. We currently look up
the string in GTK3's domain, we should use GTK4's instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2816>
This commit is contained in:
Florian Müllner 2023-07-03 19:32:13 +02:00
parent 51dc50144e
commit 5bf61d4cad

View File

@ -116,7 +116,7 @@ shell_util_get_week_start (void)
#else #else
/* Use a define to hide the string from xgettext */ /* Use a define to hide the string from xgettext */
# define GTK_WEEK_START "calendar:week_start:0" # define GTK_WEEK_START "calendar:week_start:0"
gtk_week_start = dgettext ("gtk30", GTK_WEEK_START); gtk_week_start = dgettext ("gtk40", GTK_WEEK_START);
if (strncmp (gtk_week_start, "calendar:week_start:", 20) == 0) if (strncmp (gtk_week_start, "calendar:week_start:", 20) == 0)
week_start = *(gtk_week_start + 20) - '0'; week_start = *(gtk_week_start + 20) - '0';