mirror of
https://github.com/swaywm/sway.git
synced 2026-02-16 22:05:35 -05:00
Drop sway_output.events.disable
In general wl_signal isn't well-suited for Sway: Sway doesn't need any modularity, and signals make it trickier to track down exactly what happens down the stack. Replace Sway's output disable signal with a simple list tracking for the only user.
This commit is contained in:
parent
56f2db062d
commit
a1ac2a2e93
4 changed files with 17 additions and 20 deletions
|
|
@ -9,7 +9,6 @@ struct sway_layer_surface {
|
|||
struct wl_listener map;
|
||||
struct wl_listener unmap;
|
||||
struct wl_listener surface_commit;
|
||||
struct wl_listener output_destroy;
|
||||
struct wl_listener node_destroy;
|
||||
struct wl_listener new_popup;
|
||||
|
||||
|
|
@ -19,6 +18,8 @@ struct sway_layer_surface {
|
|||
struct sway_popup_desc desc;
|
||||
|
||||
struct sway_output *output;
|
||||
struct wl_list link; // sway_output.layer_surfaces
|
||||
|
||||
struct wlr_scene_layer_surface_v1 *scene;
|
||||
struct wlr_scene_tree *tree;
|
||||
struct wlr_layer_surface_v1 *layer_surface;
|
||||
|
|
@ -41,4 +42,6 @@ struct wlr_layer_surface_v1 *toplevel_layer_surface_from_surface(
|
|||
|
||||
void arrange_layers(struct sway_output *output);
|
||||
|
||||
void destroy_layers(struct sway_output *output);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ struct sway_output {
|
|||
|
||||
bool enabled;
|
||||
list_t *workspaces;
|
||||
struct wl_list layer_surfaces; // sway_layer_surface.link
|
||||
|
||||
struct sway_output_state current;
|
||||
|
||||
|
|
@ -61,10 +62,6 @@ struct sway_output {
|
|||
struct wl_listener frame;
|
||||
struct wl_listener request_state;
|
||||
|
||||
struct {
|
||||
struct wl_signal disable;
|
||||
} events;
|
||||
|
||||
struct wlr_color_transform *color_transform;
|
||||
|
||||
struct timespec last_presentation;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue