From c5a07fac76313c2d2d6348dee20d881a639c40c8 Mon Sep 17 00:00:00 2001 From: Chris Young Date: Fri, 10 May 2019 20:32:40 +0100 Subject: Replace global current gui_window with an accessor function --- frontends/amiga/gui.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'frontends/amiga/gui.c') diff --git a/frontends/amiga/gui.c b/frontends/amiga/gui.c index fec9ed35f..4374521c1 100644 --- a/frontends/amiga/gui.c +++ b/frontends/amiga/gui.c @@ -313,7 +313,7 @@ struct ami_gui_tb_userdata { struct MinList *window_list = NULL; struct Screen *scrn = NULL; struct MsgPort *sport = NULL; -struct gui_window *cur_gw = NULL; +static struct gui_window *cur_gw = NULL; static bool ami_quit = false; @@ -377,6 +377,11 @@ static void gui_window_place_caret(struct gui_window *g, int x, int y, int heigh nsoptions_default[NSOPTION_##OPTION].value.i = VALUE /* Functions documented in gui.h */ +struct gui_window *ami_gui_get_active_gw(void) +{ + return cur_gw; +} + struct browser_window *ami_gui_get_browser_window(struct gui_window *gw) { assert(gw != NULL); -- cgit v1.2.3