diff options
Diffstat (limited to 'kvmd/validators')
-rw-r--r-- | kvmd/validators/hid.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kvmd/validators/hid.py b/kvmd/validators/hid.py index b51ff88a..bb7e26e1 100644 --- a/kvmd/validators/hid.py +++ b/kvmd/validators/hid.py @@ -42,9 +42,9 @@ def valid_hid_key(arg: Any) -> str: return check_string_in_list(arg, "Keyboard key", KEYMAP, lower=False) -def valid_hid_mouse_move(arg: Any) -> int: +def valid_hid_mouse_move(arg: Any, move_min: int=-32768, move_max: int=32767) -> int: arg = valid_number(arg, name="Mouse move") - return min(max(-32768, arg), 32767) + return min(max(move_min, arg), move_max) def valid_hid_mouse_button(arg: Any) -> str: |