al
changed/i9/anaconda-34.25.1.14-1.el9.inferit.5
parent
7ccf99b162
commit
2cfacb5e9e
@ -0,0 +1,50 @@
|
||||
From 60612774beab21f7a51c7e18011d7b245da69f3a Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Zamriy <eugene@zamriy.info>
|
||||
Date: Wed, 19 Apr 2023 12:06:57 +0300
|
||||
Subject: [PATCH 10/10] Set English as fallback language for help
|
||||
|
||||
---
|
||||
pyanaconda/core/constants.py | 4 ++++
|
||||
pyanaconda/ui/lib/help.py | 4 ++--
|
||||
2 files changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/core/constants.py b/pyanaconda/core/constants.py
|
||||
index b3c574c..350ef10 100644
|
||||
--- a/pyanaconda/core/constants.py
|
||||
+++ b/pyanaconda/core/constants.py
|
||||
@@ -73,6 +73,10 @@ ANACONDA_CONFIG_TMP = "/run/anaconda/anaconda.conf"
|
||||
# NOTE: this should be LANG_TERRITORY.CODESET, e.g. en_US.UTF-8
|
||||
DEFAULT_LANG = "ru_RU.UTF-8"
|
||||
|
||||
+# NOTE: MSVSphere change, set English as a fallback help language because
|
||||
+# we use Russian by default for UI
|
||||
+DEFAULT_HELP_LANG = "en_US.UTF-8"
|
||||
+
|
||||
DEFAULT_VC_FONT = "eurlatgr"
|
||||
|
||||
DEFAULT_KEYBOARD = "us"
|
||||
diff --git a/pyanaconda/ui/lib/help.py b/pyanaconda/ui/lib/help.py
|
||||
index 271e587..b8f424d 100644
|
||||
--- a/pyanaconda/ui/lib/help.py
|
||||
+++ b/pyanaconda/ui/lib/help.py
|
||||
@@ -25,7 +25,7 @@ from collections import namedtuple
|
||||
|
||||
from pyanaconda.anaconda_loggers import get_module_logger
|
||||
from pyanaconda.core.configuration.anaconda import conf
|
||||
-from pyanaconda.core.constants import DEFAULT_LANG, DisplayModes
|
||||
+from pyanaconda.core.constants import DEFAULT_HELP_LANG, DisplayModes
|
||||
from pyanaconda.core.util import startProgram, join_paths
|
||||
from pyanaconda.localization import find_best_locale_match
|
||||
|
||||
@@ -224,7 +224,7 @@ def _find_best_help_file(current_locale, available_files):
|
||||
:param dict available_files: a dictionary of langcodes and help paths
|
||||
:return str: a path to the best help file or None
|
||||
"""
|
||||
- for locale in (current_locale, DEFAULT_LANG):
|
||||
+ for locale in (current_locale, DEFAULT_HELP_LANG):
|
||||
best_lang = find_best_locale_match(locale, available_files.keys())
|
||||
best_path = available_files.get(best_lang, None)
|
||||
|
||||
--
|
||||
2.39.2
|
||||
|
Loading…
Reference in new issue