diff options
author | Vincent Sanders <vince@kyllikki.org> | 2019-11-05 23:05:42 +0000 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2019-11-05 23:05:42 +0000 |
commit | cbb0c05258e91fc3c3c6a421141df738fcfe7473 (patch) | |
tree | 7be33ccd8daeeb452dd429e58500c2d009180fc4 /content/handlers/html/html_redraw.c | |
parent | 78aa34e5d761c2597f24ebba89c69ac6fda2f3a8 (diff) | |
download | netsurf-cbb0c05258e91fc3c3c6a421141df738fcfe7473.tar.gz netsurf-cbb0c05258e91fc3c3c6a421141df738fcfe7473.tar.bz2 |
remove unecessary user warning calls and improve error propogation in html box
Diffstat (limited to 'content/handlers/html/html_redraw.c')
-rw-r--r-- | content/handlers/html/html_redraw.c | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/content/handlers/html/html_redraw.c b/content/handlers/html/html_redraw.c index 6216d607e..268bd62d3 100644 --- a/content/handlers/html/html_redraw.c +++ b/content/handlers/html/html_redraw.c @@ -1841,20 +1841,24 @@ bool html_redraw_box(const html_content *html, struct box *box, /* scrollbars */ if (((box->style && box->type != BOX_BR && - box->type != BOX_TABLE && box->type != BOX_INLINE && - (overflow_x == CSS_OVERFLOW_SCROLL || - overflow_x == CSS_OVERFLOW_AUTO || - overflow_y == CSS_OVERFLOW_SCROLL || - overflow_y == CSS_OVERFLOW_AUTO)) || - (box->object && content_get_type(box->object) == - CONTENT_HTML)) && box->parent != NULL) { + box->type != BOX_TABLE && box->type != BOX_INLINE && + (overflow_x == CSS_OVERFLOW_SCROLL || + overflow_x == CSS_OVERFLOW_AUTO || + overflow_y == CSS_OVERFLOW_SCROLL || + overflow_y == CSS_OVERFLOW_AUTO)) || + (box->object && content_get_type(box->object) == + CONTENT_HTML)) && box->parent != NULL) { + nserror res; has_x_scroll = box_hscrollbar_present(box); has_y_scroll = box_vscrollbar_present(box); - if (!box_handle_scrollbars((struct content *)html, - box, has_x_scroll, has_y_scroll)) + res = box_handle_scrollbars((struct content *)html, + box, has_x_scroll, has_y_scroll); + if (res != NSERROR_OK) { + NSLOG(netsurf, INFO, "%s", messages_get_errorcode(res)); return false; + } if (box->scroll_x != NULL) scrollbar_redraw(box->scroll_x, |