fix(a11y): 补全磁盘管理器AT-SPI无障碍名称 - #218
Conversation
|
Skipping CI for Draft Pull Request. |
Reviewer's GuideCompletes AT-SPI metadata for the disk manager by assigning unique object names to all previously unnamed interactive controls across 18 widget and dialog implementations, while updating their SPDX copyright years through 2026; no functional or build configuration changes are included. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
e274a53 to
c214922
Compare
Add setObjectName/setAccessibleName for interactive widgets missing AT-SPI accessibility names across 18 source files. 为18个源文件中缺失AT-SPI无障碍名称的交互控件添加setObjectName。 Log: 补全磁盘管理器AT-SPI无障碍名称 Influence: 补全后AT-SPI覆盖率达100%,无障碍工具和YouQu测试可定位控件。
c214922 to
dd855ff
Compare
deepin pr auto review🤖 AI 代码审查报告📊 总体评价
🔍 详细分析1. 语法逻辑 ✅评价: 优秀 ✅ 通过 潜在问题: 建议: 语法正确,逻辑清晰。所有新增代码均为有效的 Qt/DWidget API 调用(setObjectName、setAccessibleName),参数类型正确,调用位置合理。版权年份更新正确(2022 → 2022-2026,2022-2024 → 2022-2026)。 2. 代码质量 ✅评价: 优秀 ✅ 通过 潜在问题:
建议: 代码结构清晰,命名规范统一(ClassName+WidgetName 格式)。建议后续修复时将"Cancle"更正为"Cancel",保持与正确拼写一致。 3. 代码性能 ✅评价: 优秀 ✅ 通过 潜在问题: 建议: 性能良好,资源使用合理。setObjectName 和 setAccessibleName 均为轻量级 Qt 控件属性设置操作,仅在 UI 初始化时调用一次,对性能无影响。 4. 代码安全 🔒评价: 优秀 ✅ 通过
安全漏洞详情: 建议: 安全合规。本次变更不涉及用户输入处理、网络通信、文件操作等安全敏感场景。安全扫描器报告的18个"硬编码密钥"告警经 AI 审计全部确认为误报(均为 Qt 控件标识字符串,如"CreatePartitionTableDialogComboBox",非密钥或密码)。 💡 改进建议代码示例// 建议修正拼写错误(可选,非阻塞)
// createlvwidget.cpp - botFrameSetting()
m_cancleBtn = new DPushButton(tr("Cancel", "button"), m_botFrame);
m_cancleBtn->setObjectName("CreateLVWidgetCancelBtn"); // Cancle -> Cancel
m_cancleBtn->setAccessibleName("cancel");
// partitionwidget.cpp - botFrameSetting()
m_cancleBtn = new DPushButton(tr("Cancel", "button"), m_botFrame);
m_cancleBtn->setObjectName("PartitionWidgetCancelBtn"); // Cancle -> Cancel
m_cancleBtn->setAccessibleName("cancel");本报告由 AI 代码审查工具自动生成 |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: lzwind, re2zero 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 |
AT-SPI 无障碍名称补全
背景
对 deepin-diskmanager 仓库实施 AT-SPI 信息补全,为缺失无障碍名称的交互控件添加 setObjectName。
补全内容
覆盖率对比
编译验证
本地 cmake + make 编译通过,无新增警告。
约束
Summary by Sourcery
Complete accessibility naming for all previously unnamed interactive controls in the disk manager.
Bug Fixes:
Enhancements: