-
-
Notifications
You must be signed in to change notification settings - Fork 277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
解决 #5762 :仅合法音乐纳入背景音乐数量统计 #5798
base: main
Are you sure you want to change the base?
Conversation
建议改成 Close #5762 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
不太应该这样修复, 这会在 UI 线程读取文件夹中的所有文件的具体内容,在音乐文件较多时会造成严重卡顿。
#5762 或许加个文件扩展名判断就行?
RunInNewThread 呢,可以加个 Loader( 感觉写死扩展名判断不是很优雅 |
Dim validMusicCount As Integer = 0 | ||
For Each File In EnumerateFiles(Path & "PCL\Musics\") | ||
Try | ||
If {".ini", ".jpg", ".txt", ".cfg", ".lrc", ".db", ".png"}.Contains(File.Extension.ToLower) Then Continue For |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
改为了排除扩展名为 ini jpg txt cfg lrc db png 的文件,列表参考 ModMusic.vb#28
close #5762