Adds hide mode functionality to swaybar

This commit is contained in:
Calvin Kosmatka 2017-04-12 02:36:03 -05:00
parent c5dfe70ab1
commit 39735013b4
11 changed files with 133 additions and 93 deletions

View file

@ -110,12 +110,19 @@ struct bar_config {
* Always visible in dock mode. Visible only when modifier key is held in hide mode.
* Never visible in invisible mode.
*/
char *mode;
char *display_mode;
/**
* One of "show" or "hide".
*
* In "show" mode, it will always be shown on top of the active workspace.
*/
char *mode;
/**
* Current keybinding mode
*
* Names should probably be reworked at some point, but I'm keeping it for now
* Don't think this does anything at the moment
*/
char *hidden_state;
/**
* Id name used to identify the bar through IPC.
@ -225,9 +232,10 @@ enum ipc_feature {
IPC_FEATURE_EVENT_WINDOW = 2048,
IPC_FEATURE_EVENT_BINDING = 4096,
IPC_FEATURE_EVENT_INPUT = 8192,
IPC_FEATURE_EVENT_MODIFIER = 16384,
IPC_FEATURE_ALL_COMMANDS = 1 | 2 | 4 | 8 | 16 | 32 | 64 | 128,
IPC_FEATURE_ALL_EVENTS = 256 | 512 | 1024 | 2048 | 4096 | 8192,
IPC_FEATURE_ALL_EVENTS = 256 | 512 | 1024 | 2048 | 4096 | 8192 | 16384,
IPC_FEATURE_ALL = IPC_FEATURE_ALL_COMMANDS | IPC_FEATURE_ALL_EVENTS,
};

View file

@ -26,6 +26,7 @@ struct config {
char *font;
char *sep_symbol;
char *mode;
char *display_mode;
char *hidden_state;
bool strip_workspace_numbers;
bool binding_mode_indicator;