From 17f7ef53be5a15177e0f664fffc32b95d5ab1513 Mon Sep 17 00:00:00 2001 From: Johan Malm Date: Mon, 7 Sep 2020 19:50:19 +0100 Subject: [PATCH] output: avoid calling wlr_xdg_surface_get_geometry() Try to only call wlr_xdg_surface_get_geometry() in .commit and .map --- src/output.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/output.c b/src/output.c index 9b150abc..051514d4 100644 --- a/src/output.c +++ b/src/output.c @@ -25,9 +25,10 @@ static void render_cycle_box(struct output *output) !rc.client_side_decorations) { box = deco_max_extents(view); } else { - box = view_get_surface_geometry(view); - box.x += view->x; - box.y += view->y; + box.x = view->x; + box.y = view->y; + box.width = view->w; + box.height = view->h; } float cycle_color[] = { 0.0, 0.0, 0.0, 0.2 }; wlr_render_rect(output->server->renderer, &box, cycle_color,