mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-28 05:33:14 +00:00
TOOLS: autoload.lua: sort files case insensitive
Suggested by a user. The suggested code which was added her comes from PIL.
This commit is contained in:
@@ -28,7 +28,9 @@ function find_and_add_entries()
|
||||
if files == nil then
|
||||
return
|
||||
end
|
||||
table.sort(files)
|
||||
table.sort(files, function (a, b)
|
||||
return string.lower(a) < string.lower(b)
|
||||
end)
|
||||
if dir == "." then
|
||||
dir = ""
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user