Repository navigation
Conversation
- 将 HandleDialogOpen 中的 tauricpp::Dialog::OpenFile 替换为 直接调用 Windows API GetOpenFileNameW,彻底解决过滤器 显示乱码和选项数量随机变化的问题。 - 使用显式 push_back 方式固定三类文件过滤器: 所有文件 (*.*)、图片 (*.png;*.jpg;*.jpeg;*.gif;*.bmp)、 文档 (*.txt;*.doc;*.docx;*.xls;*.xlsx),确保每次打开 对话框时过滤器稳定且中文正常显示。 - 添加 WideToUtf8 辅助函数,用于将对话框返回的宽字符 路径正确转换为 UTF-8 编码,确保中文文件名路径正常。 - 多选模式下的路径解析逻辑保持不变,返回 UTF-8 格式 的文件路径列表供上层使用。
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.
将 HandleDialogOpen 中的 tauricpp::Dialog::OpenFile 替换为 直接调用 Windows API GetOpenFileNameW,彻底解决过滤器 显示乱码和选项数量随机变化的问题。
使用显式 push_back 方式固定三类文件过滤器: 所有文件 (.)、图片 (.png;.jpg;.jpeg;.gif;.bmp)、 文档 (.txt;.doc;.docx;.xls;.xlsx),确保每次打开 对话框时过滤器稳定且中文正常显示。
添加 WideToUtf8 辅助函数,用于将对话框返回的宽字符 路径正确转换为 UTF-8 编码,确保中文文件名路径正常。
多选模式下的路径解析逻辑保持不变,返回 UTF-8 格式 的文件路径列表供上层使用。