From 9e308d97d983b152dc920219cf4555524747c992 Mon Sep 17 00:00:00 2001 From: Xavier Del Campo Romero Date: Fri, 23 Sep 2022 04:18:17 +0200 Subject: [PATCH] gui.c: Remove unneeded condition Even if neither hcentered or vcentered are used, GUI element position must be determined by that of its parents. --- src/gui/src/gui.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/gui/src/gui.c b/src/gui/src/gui.c index 38e8565..9af530b 100644 --- a/src/gui/src/gui.c +++ b/src/gui/src/gui.c @@ -47,9 +47,7 @@ void gui_coords(const struct gui_common *const g, short *const x, { short px = p->x + p->xoff, py = p->y + p->yoff; - if (p->hcentered || p->vcentered) - gui_coords(p, &px, &py); - + gui_coords(p, &px, &py); *x += px; *y += py; }