summaryrefslogtreecommitdiffstats
path: root/DOCS/man/lua.rst
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-02-04 19:20:17 +0100
committerwm4 <wm4@nowhere>2015-02-04 23:04:21 +0100
commitf8dc5db315ce3ec3c3e9c8532f1290967bbe2336 (patch)
tree06e1691920d3db3cc01ce66e6e49b2d3c2ffdce0 /DOCS/man/lua.rst
parente163284b6802fe6375536f48cea281062294eaa2 (diff)
downloadmpv-f8dc5db315ce3ec3c3e9c8532f1290967bbe2336.tar.bz2
mpv-f8dc5db315ce3ec3c3e9c8532f1290967bbe2336.tar.xz
manpage: document hook API
This shouldn't exist and for the most part is meant to be used by the ytdl Lua script, but let's document it anyway. Since the Lua API handles all the details, it's considered much more "stable" than the raw API, which is why the raw API wasn't documented.
Diffstat (limited to 'DOCS/man/lua.rst')
-rw-r--r--DOCS/man/lua.rst17
1 files changed, 3 insertions, 14 deletions
diff --git a/DOCS/man/lua.rst b/DOCS/man/lua.rst
index 347292cd7b..7cdc29e4ab 100644
--- a/DOCS/man/lua.rst
+++ b/DOCS/man/lua.rst
@@ -745,17 +745,6 @@ guarantee a stable interface.
recommended as neutral default value. ``fn`` is the function that will be
called during execution of the hook.
- Currently existing hooks:
-
- ``on_load``
- Called when a file is to be opened, before anything is actually done.
- For example, you could read and write the ``stream-open-filename``
- property to redirect an URL to something else (consider support for
- streaming sites which rarely give the user a direct media URL), or
- you could set per-file options with by setting the property
- ``file-local-options/<option name>``. The player will wait until all
- hooks are run.
-
- ``on_unload``
- Run before closing a file, and before actually uninitializing
- everything. It's not possible to resume playback in this state.
+ See `Hooks`_ for currently existing hooks and what they do - only the hook
+ list is interesting; handling hook execution is done by the Lua script
+ function automatically.