1
1
mirror of https://github.com/swaywm/sway synced 2024-11-18 00:24:17 +01:00
Commit Graph

18 Commits

Author SHA1 Message Date
Calvin Lee
843ad38b3c Implement Tray Icons
This commit implements the StatusNotifierItem protocol, and enables
swaybar to show tray icons. It also uses `xembedsniproxy` in order to
communicate with xembed applications.
The tray is completely optional, and can be disabled on compile time
with the `enable-tray` option. Or on runtime with the bar config option
`tray_output none`.

Overview of changes:
In swaybar very little is changed outside the tray subfolder except
that all events are now polled in `event_loop.c`, this creates no
functional difference.

Six bar configuration options were added, these are detailed in
sway-bar(5)

The tray subfolder is where all protocol implementation takes place and
is organised as follows:

tray/sni_watcher.c:
	This file contains the StatusNotifierWatcher. It keeps track of
	items and hosts and reports when they come or go.
tray/tray.c
	This file contains the StatusNotifierHost. It keeps track of
	sway's version of the items and represents the tray itself.
tray/sni.c
	This file contains the StatusNotifierItem struct and all
	communication with individual items.
tray/icon.c
	This file implements the icon theme protocol. It allows for
	finding icons by name, rather than by pixmap.
tray/dbus.c
	This file allows for asynchronous DBus communication.

See #986 #343
2017-06-07 17:49:16 -07:00
Drew DeVault
9aed9d9359 UnGNUify the codebase 2017-03-10 23:41:24 -05:00
Drew DeVault
9ad1e6b40f Handle malloc failure in ipc_recv_response 2016-12-15 19:01:40 -05:00
D.B
ad4d21d60b add bar colours for focused_(workspace|statusline|separator)
If these aren't defined in config, color settings without 'focused_'
prefix are used as a fallback.
2016-11-02 18:58:33 +01:00
Ryan Dwyer
e4cb4d1b5c Fix swaybar when running on named outputs.
When using a bar on a named output, load_swaybars() requires the
output to be active (ie. in the root container), but this is not the case if
the bar is added to the last output. To fix this, load_swaybars() is now
called after the output has been added to the root container.

After fixing that, swaybar would segfault due to using the wrong index
variable when loading outputs and config.
2016-09-17 17:25:45 +10:00
D.B
c239f228c2 swaybar sends workspace name in quotes
fixes #894
2016-09-12 06:58:53 +02:00
Drew DeVault
416417a54c Reorganize includes 2016-09-01 08:18:37 -04:00
Drew DeVault
3bb880bf20 Implement configurable wrapping on bar ws scroll 2016-07-17 11:26:38 -04:00
David Eklov
8a232c8cfd Send command to sway to change workspace when workspace button is clicked 2016-07-14 17:18:01 -05:00
David Eklov
a0c8799c80 Compute what workspace button is clicked
This commit does not do anything with this information other than logging it.
2016-07-14 17:18:01 -05:00
Mykyta Holubakha
0f1cfdec61 Renamed to pango_markup 2016-04-24 20:35:21 +03:00
Mykyta Holubakha
2e6c43e62b Added plaintext_markup to swaybar IPC 2016-04-24 20:14:02 +03:00
Mikkel Oscar Lyderik
e4c1176b72 Differentiate between all or no outputs 2016-02-27 22:12:35 +01:00
Mikkel Oscar Lyderik
6d57f03028 Make single bar handle multiple outputs 2016-02-27 22:12:35 +01:00
Mikkel Oscar Lyderik
ed227f5664 swaybar: move headers to include/bar 2016-01-24 15:55:58 +01:00
Mikkel Oscar Lyderik
aa6ad09183 swaybar: rename state to bar 2016-01-24 14:22:19 +01:00
Mikkel Oscar Lyderik
6140f9c42c swaybar: Move swaybar_teardown to free_state 2016-01-24 14:22:19 +01:00
Mikkel Oscar Lyderik
fcc47cb3bd swaybar: move ipc stuff to ipc.{h,c} 2016-01-24 14:22:19 +01:00