password tooltip text adapt language

(cherry picked from commit 8796fcc87c436b0063404b3a8aec44bc74f215fe)
This commit is contained in:
sun_hai_10 2023-02-24 09:55:33 +08:00 committed by openeuler-sync-bot
parent f17a3af316
commit dd00adfd2e
2 changed files with 46 additions and 3 deletions

View File

@ -1,7 +1,7 @@
%define _empty_manifest_terminate_build 0
Name: anaconda
Version: 36.16.5
Release: 13
Release: 14
Summary: Graphical system installer
License: GPLv2+ and MIT
URL: http://fedoraproject.org/wiki/Anaconda
@ -23,9 +23,7 @@ Patch9001: bugfix-GUI-nfs-unknown-error.patch
Patch9002: bugfix-set-up-LD_PRELOAD-for-the-Storage-and-Services-module.patch
Patch9003: bugfix-Solve-the-problem-that-the-circular-loading-progress-bar-does-not-rotate.patch
Patch9004: change-inst-repo-default-value.patch
%if ! 0%{?openEuler}
Patch9005: disable-disk-encryption.patch
%endif
Patch9006: disable-ssh-login-checkbox.patch
Patch9007: fix-hostname-info.patch
Patch9008: hide-help-button.patch
@ -41,6 +39,8 @@ Patch9017: bugfix-add-SM3-with-tui.patch
Patch9018: bugfix-change-product-name-do-not-with-upper.patch
Patch9019: bugfix-adapt-active-connection-without-interface-name.patch
Patch9020: bugfix-password-tooltip-text-adapt-language.patch
%define dasbusver 1.3
%define dbusver 1.2.3
%define dnfver 3.6.0
@ -278,6 +278,13 @@ update-desktop-database &> /dev/null || :
%{_prefix}/libexec/anaconda/dd_*
%changelog
* Fri Feb 24 2023 sunhai <sunhai10@huawei.com> - 36.16.5-14
- Type:bugfix
- ID:NA
- SUG:NA
- DESC: backport password tooltip text adapt language
close disk encryption
* Tue Dec 27 2022 Chenxi Mao <chenxi.mao@suse.com> - 36.16.5-13
- Type:bugfix
- ID:NA

View File

@ -0,0 +1,36 @@
From a7de90b4741689b12137dc22f1b478bdd451762f Mon Sep 17 00:00:00 2001
From: iasunsea <iasunsea@sina.com>
Date: Thu, 23 Feb 2023 20:19:51 +0800
Subject: [PATCH] password tooltip text adapt language
---
pyanaconda/ui/gui/utils.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/ui/gui/utils.py b/pyanaconda/ui/gui/utils.py
index 282f1bc53c6..ae32ec2558b 100644
--- a/pyanaconda/ui/gui/utils.py
+++ b/pyanaconda/ui/gui/utils.py
@@ -37,6 +37,7 @@
from pyanaconda.core.async_utils import async_action_wait, run_in_loop
from pyanaconda.core.constants import NOTICEABLE_FREEZE, PASSWORD_HIDE, PASSWORD_SHOW, \
PASSWORD_HIDE_ICON, PASSWORD_SHOW_ICON
+from pyanaconda.core.i18n import _
from pyanaconda.anaconda_loggers import get_module_logger
log = get_module_logger(__name__)
@@ -542,10 +543,10 @@ def set_password_visibility(entry, visible):
if visible:
icon = PASSWORD_HIDE_ICON
- text = PASSWORD_HIDE
+ text = _(PASSWORD_HIDE)
else:
icon = PASSWORD_SHOW_ICON
- text = PASSWORD_SHOW
+ text = _(PASSWORD_SHOW)
entry.set_visibility(visible)
entry.set_icon_from_icon_name(position, icon)
--
2.27.0