From 1cd30fdb3c1f163beceb0bde7485c10a886de531 Mon Sep 17 00:00:00 2001 From: Chris Young Date: Wed, 8 May 2019 00:59:04 +0100 Subject: Move ami_(re)set_pointer (back?) into gui.c as they need to set/read the gui_window_2 structure --- frontends/amiga/gui.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'frontends/amiga/gui.c') diff --git a/frontends/amiga/gui.c b/frontends/amiga/gui.c index 2132a2408..64e152478 100644 --- a/frontends/amiga/gui.c +++ b/frontends/amiga/gui.c @@ -452,9 +452,6 @@ struct form_control *ami_gui_get_control(struct gui_window *gw) return gw->control; } -/** - * Set control (for select menu) to gui_window - */ void ami_gui_set_control(struct gui_window *gw, struct form_control *control) { assert(gw != NULL); @@ -462,6 +459,22 @@ void ami_gui_set_control(struct gui_window *gw, struct form_control *control) } +/** undocumented, or internal, or documented elsewhere **/ + +void ami_set_pointer(struct gui_window_2 *gwin, gui_pointer_shape shape, bool update) +{ + if(gwin->mouse_pointer == shape) return; + ami_update_pointer(ami_gui2_get_window(gwin), shape); + if(update == true) gwin->mouse_pointer = shape; +} + +/* reset the mouse pointer back to what NetSurf last set it as */ +void ami_reset_pointer(struct gui_window_2 *gwin) +{ + ami_update_pointer(ami_gui2_get_window(gwin), gwin->mouse_pointer); +} + + STRPTR ami_locale_langs(int *codeset) { struct Locale *locale; -- cgit v1.2.3