mirror of https://github.com/mpv-player/mpv
manpage: fix some script_message references to preferred name
This commit is contained in:
parent
46fff8d31a
commit
73aa7484f2
|
@ -634,10 +634,10 @@ Input Commands that are Possibly Subject to Change
|
|||
Send a message to all clients, and pass it the following list of arguments.
|
||||
What this message means, how many arguments it takes, and what the arguments
|
||||
mean is fully up to the receiver and the sender. Every client receives the
|
||||
message, so be careful about name clashes (or use ``script_message_to``).
|
||||
message, so be careful about name clashes (or use ``script-message-to``).
|
||||
|
||||
``script-message-to "<target>" "<arg1>" "<arg2>" ...``
|
||||
Same as ``script_message``, but send it only to the client named
|
||||
Same as ``script-message``, but send it only to the client named
|
||||
``<target>``. Each client (scripts etc.) has a unique name. For example,
|
||||
Lua scripts can get their name via ``mp.get_script_name()``.
|
||||
|
||||
|
@ -651,8 +651,8 @@ Input Commands that are Possibly Subject to Change
|
|||
separator, e.g. ``script_binding scriptname/bindingname``.
|
||||
|
||||
For completeness, here is how this command works internally. The details
|
||||
could change any time. On any matching key event, ``script_message_to``
|
||||
or ``script_message`` is called (depending on whether the script name is
|
||||
could change any time. On any matching key event, ``script-message-to``
|
||||
or ``script-message`` is called (depending on whether the script name is
|
||||
included), with the following arguments:
|
||||
|
||||
1. The string ``key-binding``.
|
||||
|
|
|
@ -454,9 +454,9 @@ are useful only in special situations.
|
|||
The level is a string, see ``msg.log`` for allowed log levels.
|
||||
|
||||
``mp.register_script_message(name, fn)``
|
||||
This is a helper to dispatch ``script_message`` or ``script_message_to``
|
||||
invocations to Lua functions. ``fn`` is called if ``script_message`` or
|
||||
``script_message_to`` (with this script as destination) is run
|
||||
This is a helper to dispatch ``script-message`` or ``script-message-to``
|
||||
invocations to Lua functions. ``fn`` is called if ``script-message`` or
|
||||
``script-message-to`` (with this script as destination) is run
|
||||
with ``name`` as first parameter. The other parameters are passed to ``fn``.
|
||||
If a message with the given name is already registered, it's overwritten.
|
||||
|
||||
|
|
|
@ -266,6 +266,6 @@ Example
|
|||
You could put this into ``input.conf`` to hide the OSC with the ``a`` key and
|
||||
to set auto mode (the default) with ``b``::
|
||||
|
||||
a script_message osc-visibility never
|
||||
b script_message osc-visibility auto
|
||||
a script-message osc-visibility never
|
||||
b script-message osc-visibility auto
|
||||
|
||||
|
|
Loading…
Reference in New Issue