mirror of https://github.com/mpv-player/mpv
select.lua: fix preselecting the current subtitle line
Fixes 4d32db21c5
.
This commit is contained in:
parent
07e5d69351
commit
ce2f501c23
|
@ -221,7 +221,7 @@ mp.add_forced_key_binding(nil, "select-subtitle-line", function ()
|
|||
for line in r.stdout:gsub("<.->", ""):gsub("{\\.-}", ""):gmatch("[^\n]+") do
|
||||
sub_lines[#sub_lines + 1] = line:sub(2):gsub("]", " ", 1)
|
||||
|
||||
if line:find("^" .. sub_start) then
|
||||
if line:find("^%[" .. sub_start) then
|
||||
default_item = #sub_lines
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue