Skip to content

[Enhancement] 下载界面的依赖列表采用按项目 slug 排序#6207

Open
ToobLac wants to merge 5 commits into
HMCL-dev:mainfrom
ToobLac:dep-order
Open

[Enhancement] 下载界面的依赖列表采用按项目 slug 排序#6207
ToobLac wants to merge 5 commits into
HMCL-dev:mainfrom
ToobLac:dep-order

Conversation

@ToobLac

@ToobLac ToobLac commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

以前是无序的

Closes #6206

@ToobLac ToobLac marked this pull request as ready for review June 22, 2026 09:52
@Glavo

Glavo commented Jun 22, 2026

Copy link
Copy Markdown
Member

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces sorting for dependency mod items in the download page, ordering them by slug while placing broken dependencies at the end. However, the custom comparator implementation violates the Java Comparator contract when handling non-DependencyModItem nodes, which can trigger a runtime IllegalArgumentException. A robust comparator implementation has been suggested to resolve this issue.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/DownloadPage.java Outdated

@3gf8jv4dv 3gf8jv4dv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

感觉效果良好 🏄

ToobLac added 2 commits June 23, 2026 21:22
# Conflicts:
#	HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/DownloadPage.java
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.

[Feature] 为模组下载的前置模组列表添加关闭自动调整顺序的配置项

3 participants