mirror of
https://github.com/swaywm/sway.git
synced 2025-10-28 05:40:16 -04:00
swaybar: deduplicate mode and workspace rendering code
The render_workspace_button and render_binding_mode_indicator functions are almost the same. This commit extracts the common rendering code into a new render_box function.
This commit is contained in:
parent
63689bfb83
commit
7e7994dbb2
2 changed files with 73 additions and 101 deletions
|
|
@ -14,6 +14,11 @@ struct box_colors {
|
|||
uint32_t text;
|
||||
};
|
||||
|
||||
struct box_size {
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
};
|
||||
|
||||
struct config_output {
|
||||
struct wl_list link; // swaybar_config::outputs
|
||||
char *name;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue