[gnome-shell] appDisplay: Look up directory- instead of category translations
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] appDisplay: Look up directory- instead of category translations
- Date: Mon, 13 Apr 2020 15:03:15 +0000 (UTC)
commit 3fac0632a8fdb78a7082dd403cbf27dd62ed91b7
Author: Florian Müllner <fmuellner gnome org>
Date: Sun Apr 12 17:15:48 2020 +0200
appDisplay: Look up directory- instead of category translations
Translations are provided by .directory files, so trying to look
up a category name without the suffix will always fail.
Commit 343b3351f1 tried to fix this previously by changing the
saved keys, but that broke existing translatable folders.
Appending the .directory suffix for the lookup instead fixes the
issue without regressing non-custom folders.
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2623
js/ui/appDisplay.js | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js
index 99c052b793..08febc4915 100644
--- a/js/ui/appDisplay.js
+++ b/js/ui/appDisplay.js
@@ -115,7 +115,8 @@ function _findBestFolderName(apps) {
}, commonCategories);
for (let category of commonCategories) {
- let translated = Shell.util_get_translated_folder_name(category);
+ const directory = '%s.directory'.format(category);
+ const translated = Shell.util_get_translated_folder_name(directory);
if (translated !== null)
return translated;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]