Use wlroots scene-graph API

Move xdg-shell and xwayland-shell surfaces to new API

Also render alt-tab on-screen-display by converting cairo-surface to
wlr_buffer
This commit is contained in:
Johan Malm 2022-02-11 23:12:45 +00:00
parent d2552232c7
commit 532656ad5b
16 changed files with 189 additions and 1465 deletions

View file

@ -216,6 +216,17 @@ server_init(struct server *server)
wl_list_init(&server->views);
wl_list_init(&server->unmanaged_surfaces);
output_init(server);
server->scene = wlr_scene_create();
if (!server->scene) {
wlr_log(WLR_ERROR, "unable to create scene");
exit(EXIT_FAILURE);
}
server->view_tree = wlr_scene_tree_create(&server->scene->node);
server->osd_tree = wlr_scene_tree_create(&server->scene->node);
wlr_scene_attach_output_layout(server->scene, server->output_layout);
/*
* Create some hands-off wlroots interfaces. The compositor is
* necessary for clients to allocate surfaces and the data device
@ -249,7 +260,6 @@ server_init(struct server *server)
*/
wlr_primary_selection_v1_device_manager_create(server->wl_display);
output_init(server);
seat_init(server);
/* Init xdg-shell */