diff options
Diffstat (limited to 'sway/config.c')
-rw-r--r-- | sway/config.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sway/config.c b/sway/config.c index 4b1bf01a..e86eda53 100644 --- a/sway/config.c +++ b/sway/config.c @@ -642,6 +642,10 @@ int sway_binding_cmp(const void *a, const void *b) { return lenient_strcmp(binda->command, bindb->command); } +int sway_binding_cmp_qsort(const void *a, const void *b) { + return sway_binding_cmp(*(void **)a, *(void **)b); +} + void free_sway_binding(struct sway_binding *binding) { if (binding->keys) { for (int i = 0; i < binding->keys->length; i++) { @@ -675,6 +679,10 @@ int sway_mouse_binding_cmp(const void *a, const void *b) { return lenient_strcmp(binda->command, bindb->command); } +int sway_mouse_binding_cmp_qsort(const void *a, const void *b) { + return sway_mouse_binding_cmp(*(void **)a, *(void **)b); +} + void free_sway_mouse_binding(struct sway_mouse_binding *binding) { if (binding->command) { free(binding->command); |