1
0
mirror of https://github.com/mpv-player/mpv synced 2025-04-01 23:00:41 +00:00
mpv/DOCS/man
CogentRedTester 099ae86717 lua: command_native_async: always callback a-sync
Previously if the raw command_native_async returned an error then the
callback function was run directly. This meant that script writers
potentially had to account for both synchronous and asynchronous logic
in the callback, which can happen even with seemingly 'safe' commands
if the mpv event queue is full.

This was at odds with the Javascript implementation of
the function, which always runs the callback asynchronously.

Now the mp.add_timeout function is used to run the callback
asynchronously on error, replicating the Javascript implementation.

This provides consistency for developers in how the callback is handled
in Lua, and increases consistency between the Lua and Javascript APIs.
2022-06-22 14:44:12 +03:00
..
af.rst various: remove trailing whitespace 2022-05-14 14:51:34 +00:00
ao.rst DOCS/ao: remove only usage of git.io link shortening service 2022-04-28 01:07:11 +03:00
changes.rst manpage: directly link interface-changes.rst in changelog section 2020-02-21 14:34:02 +01:00
console.rst console.lua: define remaining emacs keybindings 2021-11-01 23:42:16 +11:00
encode.rst manpage: explain deprecated usage of multiple items with *-add 2020-01-07 18:13:12 +01:00
input.rst DOCS/input: fix typo "NANME" -> "NAME" 2022-05-02 13:24:07 +00:00
ipc.rst DOCS: fix spelling 2021-08-24 20:44:52 +03:00
javascript.rst lua: command_native_async: always callback a-sync 2022-06-22 14:44:12 +03:00
libmpv.rst DOCS: convert mpv.io and github links to https 2021-08-17 13:42:21 +00:00
lua.rst lua: command_native_async: always callback a-sync 2022-06-22 14:44:12 +03:00
mpv.rst DOCS/{mpv,options}: document the watch later functionality 2022-04-21 15:07:56 +00:00
options.rst x11: add --x11-present option 2022-06-22 03:55:49 +00:00
osc.rst osc.lua: add idlescreen and osc-idlescreen 2022-06-04 14:48:32 +00:00
stats.rst DOCS/stats.rst: fix quoting 2021-08-09 23:57:04 +03:00
vf.rst vf_format: support forwarding/stripping film grain metadata 2022-04-05 15:02:18 +02:00
vo.rst vo: add new vaapi-wayland driver 2022-05-24 21:39:34 +00:00