backend/wayland: Linearly allocate output layers

Instaed of tracking the allocated wayland surface as part of the
output layer, just allocate them linearly. If this is acceptable and
the drm backend is also changed, we can get rid of wlr_output.layers
and wlr_output_layer completely.
This commit is contained in:
Alexander Orzechowski 2023-07-20 00:25:27 -04:00
parent 7ce4d557c5
commit 27cf4f4baa
2 changed files with 33 additions and 52 deletions

View file

@ -68,7 +68,7 @@ struct wlr_wl_presentation_feedback {
};
struct wlr_wl_output_layer {
struct wlr_addon addon;
struct wl_list link; // struct wlr_wl_output.layers
struct wl_surface *surface;
struct wl_subsurface *subsurface;
@ -96,6 +96,8 @@ struct wlr_wl_output {
struct wl_surface *surface;
int32_t hotspot_x, hotspot_y;
} cursor;
struct wl_list layers; // struct wlr_wl_output_layer.link
};
struct wlr_wl_pointer {