fix: register zip split-volume mimetypes for consistent icon display - #468
Open
pengfeixx wants to merge 1 commit into
Open
fix: register zip split-volume mimetypes for consistent icon display#468pengfeixx wants to merge 1 commit into
pengfeixx wants to merge 1 commit into
Conversation
Add application/zip mime-type registration in deepin-compressor.xml to cover zip split-archive extensions (*.z01–*.z99, *.zip.001 etc.), aligning with the existing application/x-7z-compressed handling. - Bind generic-icon name="deepin-compressor" to match 7z and main zip - glob *.z[0-9][0-9] covers WinZip-style splits (default weight 50, literal *.z64 still wins via higher specificity at same weight) - glob *.zip.[0-9][0-9][0-9] covers generic-style splits Log: PMS 268375
There was a problem hiding this comment.
Sorry @pengfeixx, you have reached your weekly rate limit of 500000 diff characters.
Please try again later or upgrade to continue using Sourcery
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: pengfeixx 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 |
Reviewer's guide (collapsed on small PRs)Reviewer's GuideRegisters split-volume ZIP mimetypes in deepin-compressor’s MIME XML so that ZIP volume parts share the same compressor icon as the main archive, aligning behavior with existing 7z handling. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
修复内容
在
src/assets/mimetype/deepin-compressor.xml中新增application/zipmime-type 注册,覆盖 zip 分卷扩展名,绑定generic-icon name="deepin-compressor",与现有application/x-7z-compressed处理方式对齐。问题原因
deepin-compressor.xml仅注册了application/x-7z-compressed(glob*.7z.*+ generic-icon),故 7z 分卷各分片图标一致;但 zip 分卷扩展名(*.z01、*.zip.001等)完全未注册,文管/gio 对这些分片回退到application/octet-stream→ 未知图标,与主.zip不一致。修复方案
*.z[0-9][0-9]:覆盖 WinZip 风格分卷(如xxx.z01),默认 weight 50,系统*.z64(literal glob)同 weight 优先级更高,不受影响*.zip.[0-9][0-9][0-9]:覆盖通用分卷风格(如xxx.zip.001)generic-icon name="deepin-compressor":与 7z 一致,覆盖系统默认package-x-generic影响范围
仅修改 mime-type 注册 XML(+5 行),无 C++/CMake 代码变更,不影响应用内 mimetype 检测逻辑。
Log: PMS 268375
Summary by Sourcery
Bug Fixes: