|
|
@ -426,12 +426,9 @@ bool ipc_initialize(struct swaybar *bar) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
free(res);
|
|
|
|
free(res);
|
|
|
|
|
|
|
|
|
|
|
|
struct swaybar_config *config = bar->config;
|
|
|
|
char *subscribe =
|
|
|
|
char subscribe[128]; // suitably large buffer
|
|
|
|
"[ \"barconfig_update\", \"bar_state_update\", \"mode\", \"workspace\" ]";
|
|
|
|
len = snprintf(subscribe, 128,
|
|
|
|
len = strlen(subscribe);
|
|
|
|
"[ \"barconfig_update\" , \"bar_state_update\" %s %s ]",
|
|
|
|
|
|
|
|
config->binding_mode_indicator ? ", \"mode\"" : "",
|
|
|
|
|
|
|
|
config->workspace_buttons ? ", \"workspace\"" : "");
|
|
|
|
|
|
|
|
free(ipc_single_command(bar->ipc_event_socketfd,
|
|
|
|
free(ipc_single_command(bar->ipc_event_socketfd,
|
|
|
|
IPC_SUBSCRIBE, subscribe, &len));
|
|
|
|
IPC_SUBSCRIBE, subscribe, &len));
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|