Lua Extensions: bring back variable callback API
So far I have already made several extensions based on following Lua functions:
'''var.add_callback( object, name, function, data )
var.del_callback( object, name, function, data )'''
I have just found out that they do not work in VLC2.1. They both disappeared also from global VLC Lua README.txt
This feature is able to add some dynamics in VLC Extensions. Subtitler (lite), Time and Previous frame work quite well. Sampler has some troubles to run properly in VLC2, but I hope that someone could help me to make it better.
-
vlc.var.add_callback(vlc.object.input(), "intf-event", input_events_handler, "Hello world!")
-
vlc.var.add_callback(vlc.object.libvlc(), "key-pressed", key_press)
I really have put all my effort in VLC Lua scripting to attract more scriptwriters that could create and share new scripts and ideas. I do not think that add_callback and del_callback are that bad that should be removed from Lua. Please, enable them again. I still hope that custom Lua scripting in VLC has a future. Please, please, ...