-
Notifications
You must be signed in to change notification settings - Fork 12
fix: add debug logging and fix user list visibility #53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#53
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#53
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#53
移除 ENABLE_DSS_SNIPE 条件编译的锁屏激活代码,将所有锁屏激活逻辑统一到 login1 会话 ActiveChanged 信号下。DSS snipe 功能导致锁屏行为不一致和重 复的激活逻辑。现在所有锁屏激活都通过 login1 会话管理器的活动状态变化来处 理,确保不同会话类型下行为一致。 此更改还移除了 pushUserFrame 中的显式模型可见性设置,因为锁屏激活逻辑现 在通过统一的激活机制正确处理可见性。 Influence: 1. 测试系统锁定时锁屏激活功能 2. 验证会话激活时锁屏正确显示 3. 测试用户切换功能仍然正常工作 4. 验证会话未激活时锁屏不会显示 5. 测试不同会话类型下的一致性 PMS: BUG-341543
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#53
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: robertkill, yixinshark The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
deepin pr auto review我来帮你分析这段代码的变更。这段代码主要涉及锁屏功能的逻辑调整。让我从几个方面进行分析:
逻辑优化:
代码质量:
性能考虑:
安全考虑:
void LockWorker::initConnections()
{
// ... 其他连接代码 ...
connect(m_login1SessionSelf, &Login1SessionSelf::ActiveChanged, this, [this](bool active) {
qCInfo(DDE_SHELL) << "DBus lock service active changed, active: " << active << ", model visible: " << m_model->visible();
if (!active) {
m_authenticating = false;
endAuthentication(m_account, AT_All);
destroyAuthentication(m_account);
} else {
handleSessionActive();
}
});
}
void LockWorker::handleSessionActive()
{
#ifdef ENABLE_DSS_SNIPE
// 处理DSS-SNIPE模式下的会话激活
if (!m_model->visible()) {
// 添加安全检查
if (isSessionSecure()) {
m_model->showLockScreen();
} else {
qCWarning(DDE_SHELL) << "Session not secure, skipping lock screen display";
}
}
#endif
}
这个改动总体上是积极的,它使锁屏逻辑更加合理和可靠。但建议按照上述建议进一步完善代码,提高其健壮性和可维护性。 |
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#53
fix: 统一锁屏激活逻辑
移除 ENABLE_DSS_SNIPE 条件编译的锁屏激活代码,将所有锁屏激活逻辑统一到
login1 会话 ActiveChanged 信号下。DSS snipe 功能导致锁屏行为不一致和重
复的激活逻辑。现在所有锁屏激活都通过 login1 会话管理器的活动状态变化来处
理,确保不同会话类型下行为一致。
此更改还移除了 pushUserFrame 中的显式模型可见性设置,因为锁屏激活逻辑现
在通过统一的激活机制正确处理可见性。
Influence:
PMS: BUG-341543