From 790e9ba6661741fe2bca3a41523ae4e6c456c10b Mon Sep 17 00:00:00 2001 From: deepin-ci-robot Date: Fri, 27 Nov 2026 02:52:10 +0000 Subject: [PATCH] sync: from linuxdeepin/dde-session-shell Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: https://github.com/linuxdeepin/dde-session-shell/pull/122 (cherry picked from commit ffab356a3a390d54997c5f9ce0685cb1b456328d) --- src/dde-lock/lockworker.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/dde-lock/lockworker.cpp b/src/dde-lock/lockworker.cpp index e4585d4b..7cfff366 100644 --- a/src/dde-lock/lockworker.cpp +++ b/src/dde-lock/lockworker.cpp @@ -977,18 +977,20 @@ void LockWorker::createAuthentication(const QString &account) if (user_ptr->isNoPasswordLogin()) { qCInfo(DDE_SHELL) << "User is no password login"; + // Quick login must lock before the core target can start Power1. + // Querying SleepLock here would wait for that target and time out. + if (m_model->isQuickLoginProcess()) { + qCInfo(DDE_SHELL) << "Quick login requires screen lock"; + setLocked(true); + m_model->setQuickLoginProcess(false); + } // 无密码登录锁定后也属于锁屏,需要设置lock属性 #ifndef ENABLE_DSS_SNIPE - if (m_model->getPowerGSettings("", "sleepLock").toBool()) { + else if (m_model->getPowerGSettings("", "sleepLock").toBool()) { #else - if (isSleepLock()) { + else if (isSleepLock()) { #endif setLocked(true); - } else if (m_model->isQuickLoginProcess()) { - //若此次程序拉起为快速登录流程,需要锁屏 - qCInfo(DDE_SHELL) << "Quick login requires screen lock"; - setLocked(true); - m_model->setQuickLoginProcess(false); } return;