Skip to content

fix: change update mode types from int to quint64#95

Merged
xionglinlin merged 1 commit into
linuxdeepin:masterfrom
xionglinlin:master
May 29, 2025
Merged

fix: change update mode types from int to quint64#95
xionglinlin merged 1 commit into
linuxdeepin:masterfrom
xionglinlin:master

Conversation

@xionglinlin

Copy link
Copy Markdown
Contributor
  1. Changed update mode related types from int/uint to quint64 for consistency with D-Bus interface
  2. Added refreshUpdateItemsChecked() method to properly update item checked states when mode changes
  3. Fixed debounce timer to use quint64 for CheckUpdateMode property changes
  4. Updated all related method signatures and property types to match

These changes were necessary because:

  1. The D-Bus interface uses 64-bit unsigned integers for update modes
  2. Using smaller types could cause data truncation and incorrect behavior
  3. The refresh logic needed to be separated from status refresh for better maintainability
  4. Ensures type safety across the entire update mode handling chain

fix: 将更新模式类型从 int 改为 quint64

  1. 将更新模式相关类型从 int/uint 改为 quint64 以保持与 D-Bus 接口一致
  2. 添加 refreshUpdateItemsChecked() 方法以便在模式变更时正确更新项目选中 状态
  3. 修复防抖定时器使用 quint64 处理 CheckUpdateMode 属性变更
  4. 更新所有相关方法签名和属性类型以匹配

这些变更是必要的因为:

  1. D-Bus 接口使用 64 位无符号整数表示更新模式
  2. 使用较小类型可能导致数据截断和错误行为
  3. 需要将刷新逻辑与状态刷新分离以提高可维护性
  4. 确保整个更新模式处理链的类型安全

pms: Bug-313905

1. Changed update mode related types from int/uint to quint64 for
consistency with D-Bus interface
2. Added refreshUpdateItemsChecked() method to properly update item
checked states when mode changes
3. Fixed debounce timer to use quint64 for CheckUpdateMode property
changes
4. Updated all related method signatures and property types to match

These changes were necessary because:
1. The D-Bus interface uses 64-bit unsigned integers for update modes
2. Using smaller types could cause data truncation and incorrect
behavior
3. The refresh logic needed to be separated from status refresh for
better maintainability
4. Ensures type safety across the entire update mode handling chain

fix: 将更新模式类型从 int 改为 quint64

1. 将更新模式相关类型从 int/uint 改为 quint64 以保持与 D-Bus 接口一致
2. 添加 refreshUpdateItemsChecked() 方法以便在模式变更时正确更新项目选中
状态
3. 修复防抖定时器使用 quint64 处理 CheckUpdateMode 属性变更
4. 更新所有相关方法签名和属性类型以匹配

这些变更是必要的因为:
1. D-Bus 接口使用 64 位无符号整数表示更新模式
2. 使用较小类型可能导致数据截断和错误行为
3. 需要将刷新逻辑与状态刷新分离以提高可维护性
4. 确保整个更新模式处理链的类型安全

pms: Bug-313905
@deepin-ci-robot

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mhduiy, xionglinlin

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@xionglinlin xionglinlin merged commit 22fe478 into linuxdeepin:master May 29, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants