summaryrefslogtreecommitdiff
path: root/render/layout.c
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2009-08-14 10:37:33 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2009-08-14 10:37:33 +0000
commit13afa0ff4c591e7800dc4c11a81d04c335418c05 (patch)
tree017f315584621f418a8bab5627aee8f8364d377b /render/layout.c
parent3549846a9aec635bea82a919c5c1e38c7163731a (diff)
downloadnetsurf-13afa0ff4c591e7800dc4c11a81d04c335418c05.tar.gz
netsurf-13afa0ff4c591e7800dc4c11a81d04c335418c05.tar.bz2
Merge Paul Blokus' selectscroll branch. Adds core select menu widget for forms and core scrollbar widget.
svn path=/trunk/netsurf/; revision=9289
Diffstat (limited to 'render/layout.c')
-rw-r--r--render/layout.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/render/layout.c b/render/layout.c
index 3ba9b038d..f2c0c158e 100644
--- a/render/layout.c
+++ b/render/layout.c
@@ -44,6 +44,7 @@
#include "content/content.h"
#include "desktop/gui.h"
#include "desktop/options.h"
+#include "desktop/scroll.h"
#include "render/box.h"
#include "render/font.h"
#include "render/form.h"
@@ -1989,8 +1990,9 @@ bool layout_line(struct box *first, int *width, int *y,
if (opt_maxwidth < opt_width)
opt_maxwidth =opt_width;
}
-
b->width = opt_maxwidth;
+ if (option_core_select_menu)
+ b->width += SCROLLBAR_WIDTH;
} else {
font_func->font_width(&fstyle, b->text,
b->length, &b->width);
@@ -2624,6 +2626,9 @@ struct box *layout_minmax_line(struct box *first,
}
b->width = opt_maxwidth;
+ if (option_core_select_menu)
+ b->width += SCROLLBAR_WIDTH;
+
} else {
font_func->font_width(&fstyle, b->text,
b->length, &b->width);