ukui-screensaver/debian/patches/0006-update-changelog.patch

100 lines
3.4 KiB
Diff
Raw Normal View History

2023-12-12 16:13:35 +08:00
From: yangmin <winner_yangmin@163.com>
Date: Tue, 12 Dec 2023 16:13:35 +0800
Subject: update changelog
---
src/lock-backend/dbusupperinterface.cpp | 4 +++-
src/widgets/authdialog.cpp | 15 +++++++++++++--
src/widgets/lockwidget.cpp | 8 +++++---
3 files changed, 21 insertions(+), 6 deletions(-)
diff --git a/src/lock-backend/dbusupperinterface.cpp b/src/lock-backend/dbusupperinterface.cpp
index f20adad..f081ea9 100644
--- a/src/lock-backend/dbusupperinterface.cpp
+++ b/src/lock-backend/dbusupperinterface.cpp
@@ -958,7 +958,9 @@ void DbusUpperInterface::onLogin1ReqLock()
QJsonObject retObj;
retObj["CmdId"] = LOCK_CMD_ID_LOGIN1_REQ_LOCK;
SendUpdateInfoSig(QString(QJsonDocument(retObj).toJson()));
- ShowScreensaver();
+ //ShowScreensaver();
+ //调用屏保会导致在两个已登录用户切锁屏,会出现屏保界面,因此改为调用锁屏
+ Lock();
}
void DbusUpperInterface::onLogin1ReqUnLock()
diff --git a/src/widgets/authdialog.cpp b/src/widgets/authdialog.cpp
index cf1c11f..ef4c014 100644
--- a/src/widgets/authdialog.cpp
+++ b/src/widgets/authdialog.cpp
@@ -905,8 +905,13 @@ void AuthDialog::onPamAuthCompleted()
m_passwordEdit->readOnly(false);
m_passwordEdit->clear();
clearMessage();
-
+ m_failMap.remove(m_curUserInfo.uid());
+ setLoginTypeTip("");
+ setUkeyTypeTip("");
+ authMode = UNKNOWN;
+ m_uCurLoginOptType = LOGINOPT_TYPE_PASSWORD;
Q_EMIT authSucceed(m_curUserInfo.name());
+
} else {
qDebug()<<"m_bRecvPrompt = "<<m_bRecvPrompt<<" m_bHasUnacknowledgedMsg = "<<m_bHasUnacknowledgedMsg;
m_bRecvPrompt = true;
@@ -1095,6 +1100,12 @@ void AuthDialog::onMessageButtonClicked()
m_passwordEdit->clear();
clearMessage();
+ m_failMap.remove(m_curUserInfo.uid());
+ setLoginTypeTip("");
+ setUkeyTypeTip("");
+ authMode = UNKNOWN;
+ m_uCurLoginOptType = LOGINOPT_TYPE_PASSWORD;
+
Q_EMIT authSucceed(m_curUserInfo.name());
} else {
m_messageButton->hide();
@@ -1436,7 +1447,7 @@ void AuthDialog::initBiometricWidget()
qDebug()<<"OptsCount:"<<m_loginOpts->getLoginOptCount();
if (m_loginOpts->getLoginOptCount() < 1){
- switchLoginOptType(LOGINOPT_TYPE_PASSWORD);
+ switchLoginOptType(LOGINOPT_TYPE_PASSWORD);
m_loginOpts->hide();
}else{
m_loginOpts->show();
diff --git a/src/widgets/lockwidget.cpp b/src/widgets/lockwidget.cpp
index 52de787..d3e69ef 100644
--- a/src/widgets/lockwidget.cpp
+++ b/src/widgets/lockwidget.cpp
@@ -992,6 +992,7 @@ void LockWidget::startAuth()
void LockWidget::onSessionActiveChanged(bool isActive)
{
+
if (isActive) {
if (m_timerChkActive && m_timerChkActive->isActive()) {
m_timerChkActive->stop();
@@ -1000,9 +1001,7 @@ void LockWidget::onSessionActiveChanged(bool isActive)
update();
}
}
-// if(authDialog) {
-// authDialog->stopAuth();
-// }
+ startAuth();
}
}
@@ -1034,6 +1033,9 @@ void LockWidget::SwitchToUser(QString strUserName)
}
}
m_timerChkActive->start();
+ stopAuth();
+ }else{
+ Q_EMIT m_modelLockDialog->setCurrentUser(strUserName);
}
}
}