sync: from linuxdeepin/dde-session-shell#502
Conversation
Synchronize source files from linuxdeepin/dde-session-shell. Source-pull-request: linuxdeepin/dde-session-shell#66
There was a problem hiding this comment.
Sorry @deepin-ci-robot, you have reached your weekly rate limit of 500000 diff characters.
Please try again later or upgrade to continue using Sourcery
deepin pr auto review这段代码是对 1. 语法逻辑
2. 代码质量
3. 代码性能
4. 代码安全
总结与改进建议这段代码的主要目的是在特定编译宏( 建议修改后的代码逻辑(仅供参考,以保持一致性): 如果非 SNIPE 模式下也应该显示图标,或者为了保持结构一致,建议统一处理。如果必须不同,请务必添加注释说明原因。 // ... 前面的代码 ...
.interface("org.freedesktop.Notifications")
.method(QString("Notify"))
#ifndef ENABLE_DSS_SNIPE
.arg(tr("Lock Screen")) // App Name
.arg(static_cast<uint>(0)) // Replaces ID
.arg(QString("dialog-warning")) // App Icon (建议非SNIPE模式下也指定一个通用图标,如dialog-warning)
#else
.arg(QString("dde-lock")) // App Name
.arg(static_cast<uint>(0)) // Replaces ID
.arg(QString("notification-lock-screen-failed")) // App Icon
#endif
.arg(QString("")) // Summary (标题)
.arg(tr("Failed to lock screen")) // Body (正文)
.arg(QStringList()) // Actions
// ... 后面的代码 ...特别注意: .arg(static_cast<uint>(0))
.arg(QString(""))实际上填补了之前该分支可能缺失的 |
|
TAG Bot New tag: 6.0.57 |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: deepin-ci-robot, 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 |
Synchronize source files from linuxdeepin/dde-session-shell.
Source-pull-request: linuxdeepin/dde-session-shell#66