[vlc-commits] cli: optimize current playlist item marker
Pierre Ynard
git at videolan.org
Fri Dec 2 17:00:34 CET 2016
vlc | branch: master | Pierre Ynard <linkfanel at yahoo.fr> | Fri Dec 2 17:00:04 2016 +0100| [e9a775915fe68a51a45db4989152a71becd4429f] | committer: Pierre Ynard
cli: optimize current playlist item marker
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e9a775915fe68a51a45db4989152a71becd4429f
---
share/lua/intf/cli.lua | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/share/lua/intf/cli.lua b/share/lua/intf/cli.lua
index 6926025..85fb6ac 100644
--- a/share/lua/intf/cli.lua
+++ b/share/lua/intf/cli.lua
@@ -212,10 +212,11 @@ function playlist_is_tree( client )
end
function playlist(name,client,arg)
+ local current = vlc.playlist.current()
function playlist0(item,prefix)
local prefix = prefix or ""
if not item.flags.disabled then
- local marker = ( item.id == vlc.playlist.current() ) and "*" or " "
+ local marker = ( item.id == current ) and "*" or " "
local str = "|"..prefix..marker..tostring(item.id).." - "..
( item.name or item.path )
if item.duration > 0 then
More information about the vlc-commits
mailing list