mirror of
https://github.com/swaywm/sway.git
synced 2025-11-02 09:01:40 -05:00
Send IPC modifier event on bar_modifier up/down
Detects when a bar modifier key is pressed/released and sends a modifier
IPC event to any listeners (usually swaybars).
This way a swaybar can listen on the modifier event and hide/show the
bar accordingly (not implemented yet)
The modifier event looks like this:
{
"change": "pressed", // or released
"modifier": "Mod4"
}
This commit is contained in:
parent
7727c9efbc
commit
c20c63b677
5 changed files with 57 additions and 8 deletions
|
|
@ -15,6 +15,12 @@ void ipc_event_barconfig_update(struct bar_config *bar);
|
|||
* Send IPC mode event to all listening clients
|
||||
*/
|
||||
void ipc_event_mode(const char *mode);
|
||||
/**
|
||||
* Sends an IPC modifier event to all listening clients. The modifier event
|
||||
* includes a key 'change' with the value of state and a key 'modifier' with
|
||||
* the name of that modifier.
|
||||
*/
|
||||
void ipc_event_modifier(uint32_t modifier, const char *state);
|
||||
const char *swayc_type_string(enum swayc_types type);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue