summaryrefslogtreecommitdiff
path: root/amiga
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2014-01-13 01:08:15 +0000
committerVincent Sanders <vince@kyllikki.org>2014-01-13 01:08:15 +0000
commit7227c29bbacbc796e9f549cf21e8bd978fde5114 (patch)
treeecd935b801f61ea1d69eea576fcaaf57e4bd909c /amiga
parent5a962586fb161651fc612ed8a8f6da99d8d22f65 (diff)
downloadnetsurf-7227c29bbacbc796e9f549cf21e8bd978fde5114.tar.gz
netsurf-7227c29bbacbc796e9f549cf21e8bd978fde5114.tar.bz2
move window scroll getter and setter into operations table
Diffstat (limited to 'amiga')
-rw-r--r--amiga/gui.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/amiga/gui.c b/amiga/gui.c
index 9ed3559f2..7c3a72afe 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -200,6 +200,9 @@ static void ami_gui_window_update_box_deferred(struct gui_window *g, bool draw);
static void ami_do_redraw(struct gui_window_2 *g);
static void ami_schedule_redraw_remove(struct gui_window_2 *gwin);
+static bool gui_window_get_scroll(struct gui_window *g, int *sx, int *sy);
+static void gui_window_set_scroll(struct gui_window *g, int sx, int sy);
+
/* accessors for default options - user option is updated if it is set as per default */
#define nsoption_default_set_int(OPTION, VALUE) \
if (nsoptions_default[NSOPTION_##OPTION].value.i == nsoptions[NSOPTION_##OPTION].value.i) \
@@ -4480,13 +4483,13 @@ void ami_get_vscroll_pos(struct gui_window_2 *gwin, ULONG *ys)
*ys /= gwin->bw->scale;
}
-bool gui_window_get_scroll(struct gui_window *g, int *sx, int *sy)
+static bool gui_window_get_scroll(struct gui_window *g, int *sx, int *sy)
{
ami_get_hscroll_pos(g->shared, (ULONG *)sx);
ami_get_vscroll_pos(g->shared, (ULONG *)sy);
}
-void gui_window_set_scroll(struct gui_window *g, int sx, int sy)
+static void gui_window_set_scroll(struct gui_window *g, int sx, int sy)
{
struct IBox *bbox;
ULONG cur_tab = 0;
@@ -5087,6 +5090,8 @@ static struct gui_window_table ami_window_table = {
.destroy = gui_window_destroy,
.redraw = gui_window_redraw_window,
.update = gui_window_update_box,
+ .get_scroll = gui_window_get_scroll,
+ .set_scroll = gui_window_set_scroll,
.set_icon = gui_window_set_icon,
.set_title = gui_window_set_title,