Skip to content

chore: add dconfig value for compositing level - #379

Merged
wineee merged 1 commit into
linuxdeepin:masterfrom
justforlxz:master
Dec 4, 2025
Merged

wineee merged 1 commit into
linuxdeepin:masterfrom
justforlxz:master

Conversation

@justforlxz

@justforlxz justforlxz commented Nov 19, 2025 •

Copy link
Copy Markdown
Member

add min_level and max_level to provide range of effect level.

min level is 1, and max level is 4.

Log:

Summary by Sourcery

Enhancements:

  • Add min_level and max_level to org.kde.kwin.compositing.json to specify the range of compositing effect levels with defaults of 1 and 4

add min_level and max_level to provide range of effect level.

min level is 1, and max level is 4.

Log:
@sourcery-ai

sourcery-ai Bot commented Nov 19, 2025

Copy link
Copy Markdown
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

This PR extends the compositing dconfig schema by introducing 'min_level' and 'max_level' properties to define a valid range for effect levels.

File-Level Changes

Change Details Files
Add level range properties to compositing schema
  • Introduce 'min_level' field with default value 1
  • Introduce 'max_level' field with default value 4
  • Update schema descriptions to reference the new range settings
configures/org.kde.kwin.compositing.json

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey there - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@deepin-ci-robot

Copy link
Copy Markdown

deepin pr auto review

我来对这个配置文件的变更进行审查:

  1. 语法逻辑:
  • JSON格式正确,结构清晰
  • 新增的"user_type_range"配置项格式规范
  • 所有必需字段都已包含(value、serial、flags、name、description等)
  1. 代码质量:
  • 配置项命名规范,使用下划线分隔
  • 多语言支持完整(英文和中文)
  • 描述信息详细清晰,有助于理解配置项用途
  • 添加了权限(permissions)和可见性(visibility)控制
  1. 代码性能:
  • 配置文件变更不会直接影响运行时性能
  • 新增的user_type_range数组结构简单,易于处理
  1. 代码安全:
  • 添加了适当的权限控制(readwrite)
  • 设置了可见性为public,符合配置项的使用场景
  • user_type的默认值从1改为0,增加了自动选择选项,提高了安全性

改进建议:

  1. 建议在user_type_range中添加注释说明每个数值的具体性能影响,帮助用户做出更好的选择。

  2. 考虑添加一个最小值和最大值的配置项,而不是使用固定的数组,这样可以更灵活地支持未来可能的扩展:

"user_type_min": {
    "value": 1,
    "description": "Minimum allowed value for user_type"
},
"user_type_max": {
    "value": 5,
    "description": "Maximum allowed value for user_type"
}
  1. 建议为每个特效等级添加性能影响说明,例如:
"performance_notes": {
    "1": "Full effects - Highest quality, highest resource usage",
    "2": "No motion effects - Good quality, moderate resource usage",
    // ... 其他等级说明
}
  1. 可以考虑添加一个配置项来控制当用户选择超出范围值时的处理策略:
"out_of_range_handling": {
    "value": "nearest",
    "description": "How to handle out of range values: 'nearest', 'min', 'max', or 'reset'"
}

这些改进建议可以让配置更加灵活和安全,同时提供更好的用户体验。

@justforlxz
justforlxz requested a review from wineee December 4, 2025 02:49
@deepin-ci-robot

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Groveer, justforlxz, wineee

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

@wineee
wineee merged commit c1afa78 into linuxdeepin:master Dec 4, 2025
16 of 19 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.

4 participants