mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-12-14 08:56:26 -05:00
Replace list_t with wl_list in wlr_wl_backend
Now wlr_backend->outputs is a list of wlr_wl_backend_output instead of wlr_output. Signed-off-by: Heghedus Razvan <heghedus.razvan@gmail.com>
This commit is contained in:
parent
e1f196a3e9
commit
d3f0878d71
5 changed files with 19 additions and 39 deletions
|
|
@ -248,8 +248,8 @@ struct wlr_output *wlr_wl_output_create(struct wlr_backend *_backend) {
|
|||
wlr_output->height = 480;
|
||||
strncpy(wlr_output->make, "wayland", sizeof(wlr_output->make));
|
||||
strncpy(wlr_output->model, "wayland", sizeof(wlr_output->model));
|
||||
snprintf(wlr_output->name, sizeof(wlr_output->name), "WL-%zd",
|
||||
backend->outputs->length + 1);
|
||||
snprintf(wlr_output->name, sizeof(wlr_output->name), "WL-%d",
|
||||
wl_list_length(&backend->outputs) + 1);
|
||||
wlr_output_update_matrix(wlr_output);
|
||||
|
||||
output->backend = backend;
|
||||
|
|
@ -306,10 +306,7 @@ struct wlr_output *wlr_wl_output_create(struct wlr_backend *_backend) {
|
|||
goto error;
|
||||
}
|
||||
|
||||
if (list_add(backend->outputs, wlr_output) == -1) {
|
||||
wlr_log(L_ERROR, "Allocation failed");
|
||||
goto error;
|
||||
}
|
||||
wl_list_insert(&backend->outputs, &output->link);
|
||||
wlr_output_create_global(wlr_output, backend->local_display);
|
||||
wl_signal_emit(&backend->backend.events.output_add, wlr_output);
|
||||
return wlr_output;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue