Merge branch '1214-main' into 'dbus-interface'

use theme icon

See merge request kylin-desktop/kylin-nm!476
This commit is contained in:
赵 世旭 2021-12-17 02:49:59 +00:00
commit 96dcf631b8
1 changed files with 3 additions and 3 deletions

View File

@ -254,7 +254,7 @@ void WlanListItem::initWlanUI()
m_showPwdButton->installEventFilter(this); m_showPwdButton->installEventFilter(this);
m_showPwdButton->setFixedSize(SHOW_PWD_BUTTON_SIZE); m_showPwdButton->setFixedSize(SHOW_PWD_BUTTON_SIZE);
m_showPwdButton->setAutoFillBackground(false); m_showPwdButton->setAutoFillBackground(false);
m_showPwdButton->setIcon(QIcon(":/res/h/hide-pwd.png")); m_showPwdButton->setIcon(QIcon::fromTheme("ukui-eye-hidden-symbolic"));
m_showPwdButton->setCursor(Qt::PointingHandCursor); m_showPwdButton->setCursor(Qt::PointingHandCursor);
connect(m_showPwdButton, &QPushButton::clicked, this, &WlanListItem::onShowPwdButtonClicked); connect(m_showPwdButton, &QPushButton::clicked, this, &WlanListItem::onShowPwdButtonClicked);
m_pwdLineEditLyt->addStretch(); m_pwdLineEditLyt->addStretch();
@ -481,10 +481,10 @@ void WlanListItem::onShowPwdButtonClicked()
} }
if (m_pwdLineEdit->echoMode() == QLineEdit::EchoMode::Password) { if (m_pwdLineEdit->echoMode() == QLineEdit::EchoMode::Password) {
m_showPwdButton->setIcon(QIcon(":/res/h/show-pwd.png")); m_showPwdButton->setIcon(QIcon::fromTheme("ukui-eye-display-symbolic"));
m_pwdLineEdit->setEchoMode(QLineEdit::EchoMode::Normal); m_pwdLineEdit->setEchoMode(QLineEdit::EchoMode::Normal);
} else { } else {
m_showPwdButton->setIcon(QIcon(":/res/h/hide-pwd.png")); m_showPwdButton->setIcon(QIcon::fromTheme("ukui-eye-hidden-symbolic"));
m_pwdLineEdit->setEchoMode(QLineEdit::EchoMode::Password); m_pwdLineEdit->setEchoMode(QLineEdit::EchoMode::Password);
} }