From 46778e6d6c2c327943c16b00e2d600933beec999 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leonardo=20Hern=C3=A1ndez=20Hern=C3=A1ndez?= Date: Mon, 21 Mar 2022 23:52:27 -0600 Subject: [PATCH] output: get scene_output by wlroots function --- output.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/output.c b/output.c index 11d0a56..c33bbe1 100644 --- a/output.c +++ b/output.c @@ -55,13 +55,7 @@ output_enable(struct cg_output *output) wlr_output_enable(wlr_output, true); wlr_output_commit(wlr_output); - struct wlr_scene_output *scene_output; - wl_list_for_each (scene_output, &output->server->scene->outputs, link) { - if (scene_output->output == wlr_output) { - output->scene_output = scene_output; - break; - } - } + output->scene_output = wlr_scene_get_scene_output(output->server->scene, wlr_output); assert(output->scene_output != NULL); }