Skip to content

Conversation

@mhduiy
Copy link
Contributor

@mhduiy mhduiy commented Dec 25, 2025

  1. Removed cursor-helper DBus service and related files
  2. Removed theme_thumb module for generating theme previews
  3. Removed themes module for theme management and scanning
  4. Removed thumbnails module for file thumbnail generation
  5. Removed thumbnailer binary
  6. Updated Makefile to exclude removed components from build
  7. These modules have been migrated to other repositories or are no longer needed

Influence:

  1. Verify build completes successfully without removed components
  2. Test remaining functionality in the API package
  3. Ensure no dependencies on removed modules in other packages
  4. Check that system theme management still works through other services
  5. Confirm file thumbnail generation is handled by other components

chore: 移除已弃用的主题和缩略图模块

  1. 移除 cursor-helper DBus 服务及相关文件
  2. 移除用于生成主题预览的 theme_thumb 模块
  3. 移除用于主题管理和扫描的 themes 模块
  4. 移除用于文件缩略图生成的 thumbnails 模块
  5. 移除 thumbnailer 二进制文件
  6. 更新 Makefile 从构建中排除已移除的组件
  7. 这些模块已迁移到其他仓库或不再需要

Influence:

  1. 验证构建在没有移除组件的情况下成功完成
  2. 测试 API 包中剩余的功能
  3. 确保其他包不依赖已移除的模块
  4. 检查系统主题管理是否仍通过其他服务正常工作
  5. 确认文件缩略图生成由其他组件处理

Summary by Sourcery

Remove deprecated theme and thumbnail-related modules and binaries from the project and update the build configuration accordingly.

Enhancements:

  • Clean up the codebase by deleting obsolete cursor-helper DBus service, theme management, and thumbnail generation modules along with their tests and test data.
  • Simplify the build by removing now-unused theme and thumbnail libraries and binaries from the Makefile targets.

1. Removed cursor-helper DBus service and related files
2. Removed theme_thumb module for generating theme previews
3. Removed themes module for theme management and scanning
4. Removed thumbnails module for file thumbnail generation
5. Removed thumbnailer binary
6. Updated Makefile to exclude removed components from build
7. These modules have been migrated to other repositories or are no
longer needed

Influence:
1. Verify build completes successfully without removed components
2. Test remaining functionality in the API package
3. Ensure no dependencies on removed modules in other packages
4. Check that system theme management still works through other services
5. Confirm file thumbnail generation is handled by other components

chore: 移除已弃用的主题和缩略图模块

1. 移除 cursor-helper DBus 服务及相关文件
2. 移除用于生成主题预览的 theme_thumb 模块
3. 移除用于主题管理和扫描的 themes 模块
4. 移除用于文件缩略图生成的 thumbnails 模块
5. 移除 thumbnailer 二进制文件
6. 更新 Makefile 从构建中排除已移除的组件
7. 这些模块已迁移到其他仓库或不再需要

Influence:
1. 验证构建在没有移除组件的情况下成功完成
2. 测试 API 包中剩余的功能
3. 确保其他包不依赖已移除的模块
4. 检查系统主题管理是否仍通过其他服务正常工作
5. 确认文件缩略图生成由其他组件处理
@mhduiy
Copy link
Contributor Author

mhduiy commented Dec 25, 2025

这些模块已经迁移至 dde-appearance

@sourcery-ai
Copy link

sourcery-ai bot commented Dec 25, 2025

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

This pull request removes several deprecated theme and thumbnail-related modules (cursor-helper DBus service, theme_thumb, themes, thumbnails, and thumbnailer) and updates the build configuration to stop building and testing them.

Flow diagram for updated build configuration without deprecated modules

flowchart LR
    A["Developer runs make"] --> B["Load Makefile"]
    B --> C["Resolve TESTS list"]
    C --> C1["Run Go tests for remaining modules"]

    %% Previously included tests (now removed)
    C -.skipped.-> T1["cursor-helper tests (removed)"]
    C -.skipped.-> T2["theme_thumb tests (removed)"]
    C -.skipped.-> T3["themes tests (removed)"]
    C -.skipped.-> T4["thumbnailer tests (removed)"]
    C -.skipped.-> T5["thumbnails tests (removed)"]

    C1 --> D["Resolve LIBRARIES list"]
    D --> D1["Build remaining libraries"]

    %% Previously built libraries (now removed)
    D -.skipped.-> L1["thumbnails library (removed)"]
    D -.skipped.-> L2["themes library (removed)"]
    D -.skipped.-> L3["theme_thumb library (removed)"]

    D1 --> E["Resolve BINARIES list"]
    E --> E1["Build remaining binaries"]

    %% Previously built binaries (now removed)
    E -.skipped.-> B1["thumbnailer binary (removed)"]
    E -.skipped.-> B2["cursor-helper binary (removed)"]

    E1 --> F["Install or package artifacts"]

    classDef skipped stroke:#ff0000,color:#ff0000;
    class T1,T2,T3,T4,T5,L1,L2,L3,B1,B2 skipped;
Loading

File-Level Changes

Change Details Files
Stop building and testing deprecated theme/thumbnail components in the Makefile.
  • Removed cursor-helper package from the TESTS list.
  • Removed all theme_thumb, themes, thumbnails, and thumbnailer packages from the TESTS list.
  • Removed thumbnail-related libraries from the LIBRARIES list.
  • Removed thumbnailer and cursor-helper from the BINARIES list.
Makefile
Delete cursor-helper DBus service implementation and service file.
  • Removed cursor-helper main program implementation.
  • Removed auto-generated DBus-exported methods file for cursor-helper.
  • Removed cursor-helper unit tests.
  • Removed the org.deepin.dde.CursorHelper1.service DBus service descriptor from misc/services.
cursor-helper/cursor_helper_test.go
cursor-helper/exported_methods_auto.go
cursor-helper/main.go
misc/services/org.deepin.dde.CursorHelper1.service
Delete theme_thumb module used for generating theme previews.
  • Removed common utilities for theme thumbnail generation.
  • Removed cursor theme thumbnail generation code.
  • Removed GTK theme thumbnail generation code.
  • Removed icon theme thumbnail generation code.
  • Removed theme_thumb entry point and orchestration code.
theme_thumb/common/common.go
theme_thumb/cursor/cursor.go
theme_thumb/cursor/load.go
theme_thumb/gtk/gtk.go
theme_thumb/icon/icon.go
theme_thumb/thumb.go
Delete themes module responsible for theme management and scanning.
  • Removed C and Go code for cursor theme handling, including headers and implementation.
  • Removed GTK2/GTK3 theme handling code and tests.
  • Removed Qt cursor integration code.
  • Removed theme scanner implementation and tests along with associated testdata for themes and icons.
  • Removed core theme settings and theme model implementation and tests, including supporting testdata files.
themes/cursor.c
themes/cursor.go
themes/cursor.h
themes/gtk2.go
themes/gtk2_test.go
themes/gtk3.go
themes/gtk3_test.go
themes/qt_cursor.c
themes/scanner/scanner.go
themes/scanner/scanner_test.go
themes/scanner/testdata/Icons/Icon1/index.theme
themes/scanner/testdata/Icons/Icon2/index.theme
themes/scanner/testdata/Themes/Gtk1/gtk-2.0/gtkrc
themes/scanner/testdata/Themes/Gtk1/gtk-3.0/settings.ini
themes/scanner/testdata/Themes/Gtk1/index.theme
themes/scanner/testdata/Themes/Gtk1/metacity-1/metacity-theme-3.xml
themes/scanner/testdata/Themes/Gtk2/gtk-2.0/gtkrc
themes/scanner/testdata/Themes/Gtk2/gtk-3.0/settings.ini
themes/scanner/testdata/Themes/Gtk2/index.theme
themes/scanner/testdata/Themes/Gtk2/metacity-1/metacity-theme-3.xml
themes/scanner/testdata/gtk_paper.theme
themes/scanner/testdata/gtk_paper_hidden.theme
themes/scanner/testdata/icon_deepin.theme
themes/scanner/testdata/icon_deepin_hidden.theme
themes/settings.go
themes/testdata/gtkrc-2.0
themes/testdata/settings.ini
themes/theme.go
themes/theme_test.go
Delete thumbnails module and thumbnailer binary used for file thumbnail generation.
  • Removed cursor thumbnail generation logic, including xcur2png conversion.
  • Removed font thumbnail generation C and Go code and headers.
  • Removed GTK thumbnail generation logic.
  • Removed icon thumbnail generation C and Go code and headers.
  • Removed image thumbnail conversion and wrapper implementations in C and Go.
  • Removed thumbnail loader, PDF thumbnail generation code and C helpers, and text thumbnail generation code and C helpers.
  • Removed top-level thumbnails orchestrator implementation and tests.
  • Removed thumbnailer CLI entry point.
thumbnailer/main.go
thumbnails/cursor/cursor.go
thumbnails/cursor/thumbnail.go
thumbnails/cursor/xcur2png.go
thumbnails/font/font.go
thumbnails/font/thumbnail.c
thumbnails/font/thumbnail.h
thumbnails/font/wrapper.go
thumbnails/gtk/gtk.go
thumbnails/icon/icon.c
thumbnails/icon/icon.go
thumbnails/icon/icon.h
thumbnails/icon/thumbnail.go
thumbnails/icon/wrapper.go
thumbnails/images/convert.c
thumbnails/images/convert.h
thumbnails/images/images.go
thumbnails/images/wrapper.go
thumbnails/loader/loader.go
thumbnails/pdf/pdf.go
thumbnails/pdf/thumbnail.c
thumbnails/pdf/thumbnail.h
thumbnails/pdf/wrapper.go
thumbnails/text/text.c
thumbnails/text/text.go
thumbnails/text/text.h
thumbnails/text/wrapper.go
thumbnails/thumbnails.go
thumbnails/thumbnails_test.go

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

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • Since the DBus service, binaries, and libraries are removed, scan the repo for remaining references to cursor-helper, thumbnailer, thumbnails, themes, and theme_thumb (e.g., in other Makefile targets, init/service configs, or code) and clean up any leftovers to avoid build-time or runtime confusion.
  • Consider also pruning any now-unused build artifacts or install rules related to the removed modules (e.g., installation paths, install-* targets, or generated files tied to those components) so the Makefile accurately reflects the current set of deliverables.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Since the DBus service, binaries, and libraries are removed, scan the repo for remaining references to `cursor-helper`, `thumbnailer`, `thumbnails`, `themes`, and `theme_thumb` (e.g., in other Makefile targets, init/service configs, or code) and clean up any leftovers to avoid build-time or runtime confusion.
- Consider also pruning any now-unused build artifacts or install rules related to the removed modules (e.g., installation paths, `install-*` targets, or generated files tied to those components) so the Makefile accurately reflects the current set of deliverables.

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

deepin pr auto review

我来帮你分析这个git diff。这个diff主要删除了与cursor(鼠标指针)、theme(主题)和thumbnail(缩略图)相关的代码文件。让我从几个方面来分析:

  1. 语法逻辑:
  • 删除操作本身在语法上是正确的,没有引入任何语法错误
  • 删除的代码文件之间相互依赖,整体删除是合理的
  1. 代码质量:
  • 删除了大量相关功能模块,包括:
    • cursor-helper:鼠标指针主题相关功能
    • theme_thumb:主题缩略图生成功能
    • thumbnails:各类文件缩略图生成功能
    • themes:主题管理相关功能
  • 这些模块的删除说明项目正在进行功能简化或重构
  1. 代码性能:
  • 删除这些模块会减少编译后的二进制文件大小
  • 移除了缩略图生成等可能消耗CPU的功能,可能会提升性能
  • 但同时也移除了一些用户可能需要的功能
  1. 代码安全:
  • 删除的代码主要涉及UI和主题相关,没有明显的安全隐患
  • 移除了一些文件操作相关的代码,降低了潜在的文件系统安全风险

改进建议:

  1. 如果这是功能简化:
  • 建议确保删除的功能确实不再需要
  • 考虑是否需要提供替代方案
  • 应该更新相关文档说明这些功能已被移除
  1. 如果这是重构的一部分:
  • 建议确保新的实现方案已经准备就绪
  • 应该保留必要的接口兼容性
  • 需要更新相关的API文档
  1. 其他建议:
  • 建议在提交信息中详细说明删除这些功能的原因
  • 如果是永久删除,建议清理相关的配置文件和依赖
  • 考虑是否需要数据迁移方案

总的来说,这次删除操作在技术上是合理的,但需要确保有充分的业务理由,并且已经做好了相应的替代或迁移方案。建议在后续开发中密切关注这些功能模块的替代实现。

@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

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

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

@mhduiy mhduiy merged commit e9b7184 into linuxdeepin:master Dec 25, 2025
17 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