aboutsummaryrefslogtreecommitdiffhomepage
path: root/DOCS
diff options
context:
space:
mode:
authorGravatar wm4 <wm4@nowhere>2018-04-28 18:14:43 +0200
committerGravatar Jan Ekström <jeebjp@gmail.com>2018-04-29 02:21:32 +0300
commit7dd69ef77c6aa80067c13f76aa0b78d63fbc4eda (patch)
tree58036a7590ed3007b5ffa2ea9e3ee566586f79d9 /DOCS
parent573159734271c3969ffb3818af9dde3b116f9c92 (diff)
command: change cycle-value command behavior
Instead of using an internal counter to keep track of the value that was set last, attempt to find the current value of the property/option in the value list, and then set the next value in the list. There are some potential problems. If a property refuses to accept a specific value, the cycle-values command will fail, and start from the same position again. It can't know that it's supposed to skip the next value. The same can happen to properties which behave "strangely", such as the "aspect" property, which will return the current aspect if you write "-1" to it. As a consequence, cycle-values can appear to get "stuck". I still think the new behavior is what users expect more, and which is generally more useful. We won't restore the ability to get the old behavior, unless we decide to revert this commit entirely. Fixes #5772, and hopefully other complaints.
Diffstat (limited to 'DOCS')
-rw-r--r--DOCS/interface-changes.rst2
-rw-r--r--DOCS/man/input.rst19
-rw-r--r--DOCS/man/options.rst2
3 files changed, 9 insertions, 14 deletions
diff --git a/DOCS/interface-changes.rst b/DOCS/interface-changes.rst
index d9fa295fc4..a21f50e0fa 100644
--- a/DOCS/interface-changes.rst
+++ b/DOCS/interface-changes.rst
@@ -98,6 +98,8 @@ Interface changes
nobody wants to fix it. Automatic 3D down-conversion to 2D is also broken,
although you can just insert the stereo3d filter manually. The obscurity
of 3D content doesn't justify such an option anyway.
+ - change cycle-values command to use the current value, instead of an
+ internal counter that remembered the current position.
--- mpv 0.28.0 ---
- rename --hwdec=mediacodec option to mediacodec-copy, to reflect
conventions followed by other hardware video decoding APIs
diff --git a/DOCS/man/input.rst b/DOCS/man/input.rst
index 4a59a919f0..58e2b9c27d 100644
--- a/DOCS/man/input.rst
+++ b/DOCS/man/input.rst
@@ -514,21 +514,14 @@ Input Commands that are Possibly Subject to Change
``cycle-values ["!reverse"] <property> "<value1>" "<value2>" ...``
Cycle through a list of values. Each invocation of the command will set the
- given property to the next value in the list. The command maintains an
- internal counter which value to pick next, and which is initially 0. It is
- reset to 0 once the last value is reached.
-
- The internal counter is associated using the property name and the value
- list. If multiple commands (bound to different keys) use the same name
- and value list, they will share the internal counter.
+ given property to the next value in the list. The command will use the
+ current value of the property/option, and use it to determine the current
+ position in the list of values. Once it has found it, it will set the
+ next value in the list (wrapping around to the first item if needed).
The special argument ``!reverse`` can be used to cycle the value list in
- reverse. Compared with a command that just lists the value in reverse, this
- command will actually share the internal counter with the forward-cycling
- key binding (as long as the rest of the arguments are the same).
-
- Note that there is a static limit of (as of this writing) 10 arguments
- (this limit could be raised on demand).
+ reverse. The only advantage is that you don't need to reverse the value
+ list yourself when adding a second key binding for cycling backwards.
``enable-section "<section>" [flags]``
Enable all key bindings in the named input section.
diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst
index 069363dfd0..d147800ea3 100644
--- a/DOCS/man/options.rst
+++ b/DOCS/man/options.rst
@@ -2249,7 +2249,7 @@ Window
.. admonition:: Note (X11)
- This option does works properly only with window managers which
+ This option works properly only with window managers which
understand the EWMH ``_NET_WM_FULLSCREEN_MONITORS`` hint.
.. admonition:: Note (OS X)