diff options
Diffstat (limited to 'render/box.c')
-rw-r--r-- | render/box.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/render/box.c b/render/box.c index 7111f1a6e..5a0735e24 100644 --- a/render/box.c +++ b/render/box.c @@ -1151,11 +1151,12 @@ bool box_handle_scrollbars(struct content *c, struct box *box, } data->c = c; data->box = box; - if (!scrollbar_create(false, visible_height, + if (scrollbar_create(false, visible_height, full_height, visible_height, data, html_overflow_scroll_callback, - &(box->scroll_y))) + &(box->scroll_y)) != NSERROR_OK) { return false; + } } else { scrollbar_set_extents(box->scroll_y, visible_height, visible_height, full_height); @@ -1171,13 +1172,14 @@ bool box_handle_scrollbars(struct content *c, struct box *box, } data->c = c; data->box = box; - if (!scrollbar_create(true, + if (scrollbar_create(true, visible_width - (right ? SCROLLBAR_WIDTH : 0), full_width, visible_width, data, html_overflow_scroll_callback, - &box->scroll_x)) + &box->scroll_x) != NSERROR_OK) { return false; + } } else { scrollbar_set_extents(box->scroll_x, visible_width - |