summaryrefslogtreecommitdiffstats
path: root/input/input.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-09-22 06:15:36 +0200
committerwm4 <wm4@nowhere>2012-10-12 10:10:31 +0200
commit45b432f4c32be5cab798a0658d9461b3a40a6d94 (patch)
tree3a460173adb5e79a648f1b04fb39d73ba4d6a721 /input/input.h
parent9939776e5ee70818d9cc4a5a7cd9f09da4239164 (diff)
downloadmpv-45b432f4c32be5cab798a0658d9461b3a40a6d94.tar.bz2
mpv-45b432f4c32be5cab798a0658d9461b3a40a6d94.tar.xz
commands: replace "switch" with "add" and "cycle"
Now it depends on the command whether a property wraps around, or stops at min/max valid property value. For practically all properties, it's quite unambiguous what the "switch" command should have done, and there's technically no need to replace it with these new commands. More over, most properties that cycle are boolean anyway. But it seems more orthogonal to make the difference explicit, rather than hardcoding it. Having different commands also makes it more explicit to the user what these commands do, both just due to the naming, and what wrapping policy is used. The code is simpler too.
Diffstat (limited to 'input/input.h')
-rw-r--r--input/input.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/input/input.h b/input/input.h
index 158d71b8ac..d3abc6f4c8 100644
--- a/input/input.h
+++ b/input/input.h
@@ -54,7 +54,8 @@ enum mp_command_type {
MP_CMD_RADIO_SET_CHANNEL,
MP_CMD_RADIO_SET_FREQ,
MP_CMD_SET_MOUSE_POS,
- MP_CMD_SWITCH,
+ MP_CMD_ADD,
+ MP_CMD_CYCLE,
MP_CMD_RADIO_STEP_FREQ,
MP_CMD_TV_STEP_FREQ,
MP_CMD_TV_START_SCAN,