summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2017-01-03 18:03:43 +0000
committerChris Young <chris@unsatisfactorysoftware.co.uk>2017-01-03 18:03:43 +0000
commit2e11f7f3cbd7d563cb525a26ce79d76502ba7686 (patch)
tree4e76b5056f15fc9feb3050b63a4d25d4cb0ff2ab
parent5eb7ee97ed641e152c488dab6c33c37d0635e48b (diff)
downloadnetsurf-2e11f7f3cbd7d563cb525a26ce79d76502ba7686.tar.gz
netsurf-2e11f7f3cbd7d563cb525a26ce79d76502ba7686.tar.bz2
less cranky scrollbars
-rw-r--r--frontends/amiga/corewindow.c22
1 files changed, 8 insertions, 14 deletions
diff --git a/frontends/amiga/corewindow.c b/frontends/amiga/corewindow.c
index e5d289a88..59fc3e16b 100644
--- a/frontends/amiga/corewindow.c
+++ b/frontends/amiga/corewindow.c
@@ -616,28 +616,22 @@ ami_cw_update_size(struct core_window *cw, int width, int height)
if(width == -1) {
ami_cw_toggle_scrollbar(ami_cw, false, false);
- return;
+ } else {
+ ami_cw_toggle_scrollbar(ami_cw, false, true);
+ RefreshSetGadgetAttrs((struct Gadget *)ami_cw->objects[GID_CW_HSCROLL], ami_cw->win, NULL,
+ SCROLLER_Total, (ULONG)width,
+ SCROLLER_Visible, win_w,
+ TAG_DONE);
}
if(height == -1) {
ami_cw_toggle_scrollbar(ami_cw, true, false);
- return;
- }
-
- if(ami_cw->objects[GID_CW_VSCROLL]) {
+ } else {
ami_cw_toggle_scrollbar(ami_cw, true, true);
RefreshSetGadgetAttrs((struct Gadget *)ami_cw->objects[GID_CW_VSCROLL], ami_cw->win, NULL,
SCROLLER_Total, height,
SCROLLER_Visible, win_h,
- TAG_DONE);
- }
-
- if(ami_cw->objects[GID_CW_HSCROLL]) {
- ami_cw_toggle_scrollbar(ami_cw, false, true);
- RefreshSetGadgetAttrs((struct Gadget *)ami_cw->objects[GID_CW_HSCROLL], ami_cw->win, NULL,
- SCROLLER_Total, (ULONG)width,
- SCROLLER_Visible, win_w,
- TAG_DONE);
+ TAG_DONE);
}
}