diff options
author | Manuel Stoeckl <code@mstoeckl.com> | 2021-02-02 19:54:35 -0500 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2021-02-04 09:49:06 +0100 |
commit | cb3c7276324b5b0862088df9ffe5498998edae91 (patch) | |
tree | b4576f3715e53300794f92e4c6339df0ac1e447a /sway/commands/input.c | |
parent | xdg-foreign: add v1 and v2 implementations (diff) | |
download | sway-cb3c7276324b5b0862088df9ffe5498998edae91.tar.gz sway-cb3c7276324b5b0862088df9ffe5498998edae91.tar.zst sway-cb3c7276324b5b0862088df9ffe5498998edae91.zip |
Declare all struct cmd_handler arrays const
And make the functions handling these arrays use const types.
Diffstat (limited to 'sway/commands/input.c')
-rw-r--r-- | sway/commands/input.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/commands/input.c b/sway/commands/input.c index c9bb8e06..77acb671 100644 --- a/sway/commands/input.c +++ b/sway/commands/input.c | |||
@@ -7,7 +7,7 @@ | |||
7 | #include "stringop.h" | 7 | #include "stringop.h" |
8 | 8 | ||
9 | // must be in order for the bsearch | 9 | // must be in order for the bsearch |
10 | static struct cmd_handler input_handlers[] = { | 10 | static const struct cmd_handler input_handlers[] = { |
11 | { "accel_profile", input_cmd_accel_profile }, | 11 | { "accel_profile", input_cmd_accel_profile }, |
12 | { "calibration_matrix", input_cmd_calibration_matrix }, | 12 | { "calibration_matrix", input_cmd_calibration_matrix }, |
13 | { "click_method", input_cmd_click_method }, | 13 | { "click_method", input_cmd_click_method }, |
@@ -40,7 +40,7 @@ static struct cmd_handler input_handlers[] = { | |||
40 | }; | 40 | }; |
41 | 41 | ||
42 | // must be in order for the bsearch | 42 | // must be in order for the bsearch |
43 | static struct cmd_handler input_config_handlers[] = { | 43 | static const struct cmd_handler input_config_handlers[] = { |
44 | { "xkb_capslock", input_cmd_xkb_capslock }, | 44 | { "xkb_capslock", input_cmd_xkb_capslock }, |
45 | { "xkb_numlock", input_cmd_xkb_numlock }, | 45 | { "xkb_numlock", input_cmd_xkb_numlock }, |
46 | }; | 46 | }; |