mirror of
https://github.com/mpv-player/mpv
synced 2025-02-17 21:27:08 +00:00
lua: remove mp.suspend, resume and resume_all
These functions were deprecated in v0.21.0 and no-ops since v0.23.0. The matching client API functions were removed in the previous commit.
This commit is contained in:
parent
632059816a
commit
dfcd561ba9
@ -73,12 +73,6 @@ Unsupported Lua APIs and their JS alternatives
|
||||
|
||||
``utils.to_string(v)`` see ``dump`` below.
|
||||
|
||||
``mp.suspend()`` JS: none (deprecated).
|
||||
|
||||
``mp.resume()`` JS: none (deprecated).
|
||||
|
||||
``mp.resume_all()`` JS: none (deprecated).
|
||||
|
||||
``mp.get_next_timeout()`` see event loop below.
|
||||
|
||||
``mp.dispatch_events([allow_wait])`` see event loop below.
|
||||
|
@ -527,18 +527,6 @@ Advanced mp functions
|
||||
These also live in the ``mp`` module, but are documented separately as they
|
||||
are useful only in special situations.
|
||||
|
||||
``mp.suspend()``
|
||||
This function has been deprecated in mpv 0.21.0 and does nothing starting
|
||||
with mpv 0.23.0 (no replacement).
|
||||
|
||||
``mp.resume()``
|
||||
This function has been deprecated in mpv 0.21.0 and does nothing starting
|
||||
with mpv 0.23.0 (no replacement).
|
||||
|
||||
``mp.resume_all()``
|
||||
This function has been deprecated in mpv 0.21.0 and does nothing starting
|
||||
with mpv 0.23.0 (no replacement).
|
||||
|
||||
``mp.get_wakeup_pipe()``
|
||||
Calls ``mpv_get_wakeup_pipe()`` and returns the read end of the wakeup
|
||||
pipe. This is deprecated, but still works. (See ``client.h`` for details.)
|
||||
|
20
player/lua.c
20
player/lua.c
@ -539,23 +539,6 @@ static int script_get_script_directory(lua_State *L)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int script_suspend(lua_State *L)
|
||||
{
|
||||
struct script_ctx *ctx = get_ctx(L);
|
||||
MP_ERR(ctx, "mp.suspend() is deprecated and does nothing.\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int script_resume(lua_State *L)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int script_resume_all(lua_State *L)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void pushnode(lua_State *L, mpv_node *node);
|
||||
|
||||
static int script_raw_wait_event(lua_State *L, void *tmp)
|
||||
@ -1220,9 +1203,6 @@ struct fn_entry {
|
||||
|
||||
static const struct fn_entry main_fns[] = {
|
||||
FN_ENTRY(log),
|
||||
FN_ENTRY(suspend),
|
||||
FN_ENTRY(resume),
|
||||
FN_ENTRY(resume_all),
|
||||
AF_ENTRY(raw_wait_event),
|
||||
FN_ENTRY(request_event),
|
||||
FN_ENTRY(find_config_file),
|
||||
|
@ -542,9 +542,6 @@ function mp.dispatch_events(allow_wait)
|
||||
end
|
||||
end
|
||||
end
|
||||
-- Resume playloop - important especially if an error happened while
|
||||
-- suspended, and the error was handled, but no resume was done.
|
||||
mp.resume_all()
|
||||
if allow_wait ~= true then
|
||||
return
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user