summaryrefslogtreecommitdiffstats
path: root/sway/ipc-server.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/ipc-server.c')
-rw-r--r--sway/ipc-server.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/sway/ipc-server.c b/sway/ipc-server.c
index e575081b..0442a2f9 100644
--- a/sway/ipc-server.c
+++ b/sway/ipc-server.c
@@ -343,10 +343,8 @@ void ipc_client_handle_command(struct ipc_client *client) {
343 client->subscribed_events |= event_mask(IPC_EVENT_WINDOW); 343 client->subscribed_events |= event_mask(IPC_EVENT_WINDOW);
344 } else if (strcmp(event_type, "modifier") == 0) { 344 } else if (strcmp(event_type, "modifier") == 0) {
345 client->subscribed_events |= event_mask(IPC_EVENT_MODIFIER); 345 client->subscribed_events |= event_mask(IPC_EVENT_MODIFIER);
346#if SWAY_BINDING_EVENT
347 } else if (strcmp(event_type, "binding") == 0) { 346 } else if (strcmp(event_type, "binding") == 0) {
348 client->subscribed_events |= event_mask(IPC_EVENT_BINDING); 347 client->subscribed_events |= event_mask(IPC_EVENT_BINDING);
349#endif
350 } else { 348 } else {
351 ipc_send_reply(client, "{\"success\": false}", 18); 349 ipc_send_reply(client, "{\"success\": false}", 18);
352 json_object_put(request); 350 json_object_put(request);
@@ -639,7 +637,6 @@ void ipc_event_modifier(uint32_t modifier, const char *state) {
639 json_object_put(obj); // free 637 json_object_put(obj); // free
640} 638}
641 639
642#if SWAY_BINDING_EVENT
643static void ipc_event_binding(json_object *sb_obj) { 640static void ipc_event_binding(json_object *sb_obj) {
644 sway_log(L_DEBUG, "Sending binding::run event"); 641 sway_log(L_DEBUG, "Sending binding::run event");
645 json_object *obj = json_object_new_object(); 642 json_object *obj = json_object_new_object();
@@ -651,10 +648,8 @@ static void ipc_event_binding(json_object *sb_obj) {
651 648
652 json_object_put(obj); // free 649 json_object_put(obj); // free
653} 650}
654#endif
655 651
656void ipc_event_binding_keyboard(struct sway_binding *sb) { 652void ipc_event_binding_keyboard(struct sway_binding *sb) {
657#if SWAY_BINDING_EVENT
658 json_object *sb_obj = json_object_new_object(); 653 json_object *sb_obj = json_object_new_object();
659 json_object_object_add(sb_obj, "command", json_object_new_string(sb->command)); 654 json_object_object_add(sb_obj, "command", json_object_new_string(sb->command));
660 655
@@ -705,5 +700,4 @@ void ipc_event_binding_keyboard(struct sway_binding *sb) {
705 json_object_object_add(sb_obj, "input_type", json_object_new_string("keyboard")); 700 json_object_object_add(sb_obj, "input_type", json_object_new_string("keyboard"));
706 701
707 ipc_event_binding(sb_obj); 702 ipc_event_binding(sb_obj);
708#endif
709} 703}