mirror of
https://github.com/swaywm/sway.git
synced 2025-04-03 19:07:45 +03:00
swaybar: do not retry search for tray icons
In case a tray icon cannot be found or does not have a desirable size, swaybar retries the search again and again, which increases load on disk and CPU. This commit solves it by storing target_size for each icon, so that swaybar does not search for an icon of some size if it already tried to. Fixes #3789.
This commit is contained in:
parent
a5b6f40937
commit
fa0abaf7cf
3 changed files with 62 additions and 52 deletions
|
@ -20,6 +20,7 @@ struct swaybar_sni {
|
|||
cairo_surface_t *icon;
|
||||
int min_size;
|
||||
int max_size;
|
||||
int target_size;
|
||||
|
||||
// dbus properties
|
||||
char *watcher_id;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue