From cd71017eaaffc1d615e10b9eb89b0a25852f128a Mon Sep 17 00:00:00 2001 From: Andynium Date: Sat, 28 Feb 2026 11:43:46 +0100 Subject: [PATCH] amiga: size pageinfo draw area instead of window hack --- frontends/amiga/pageinfo.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/frontends/amiga/pageinfo.c b/frontends/amiga/pageinfo.c index 3ff223d7d..b0ffeb1aa 100644 --- a/frontends/amiga/pageinfo.c +++ b/frontends/amiga/pageinfo.c @@ -269,12 +269,14 @@ nserror ami_pageinfo_open(struct browser_window *bw, ULONG left, ULONG top) } if(page_info_get_size(ncwin->pi, &width, &height) == NSERROR_OK) { - /* Set window to the correct size. - * TODO: this should really set the size of ncwin->core.objects[GID_CW_DRAW] - * and let the window adjust, here we've hardcoded to add 6x4px as that's - * what window.class does before v45. - */ - SetAttrs(ncwin->core.objects[GID_CW_WIN], WA_InnerWidth, width + 6, WA_InnerHeight, height + 4, TAG_DONE); + /* Set draw area size and let the window/layout adjust (OS3-safe) */ + SetAttrs(ncwin->core.objects[GID_CW_DRAW], + GA_Width, width, + GA_Height, height, + TAG_DONE); + + RethinkLayout((struct Gadget *)ncwin->core.objects[GID_CW_WIN], + NULL, NULL, TRUE); } return NSERROR_OK;