From 4ba282c9c9dafa124237aa50312125e5a003c375 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Sun, 6 Nov 2011 11:26:52 +0000 Subject: Fix bug #3433954: make containing_block available to layout_table so it can resolve percentage height specified on an absolutely-positioned table. svn path=/trunk/netsurf/; revision=13130 --- render/layout.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'render') diff --git a/render/layout.c b/render/layout.c index c4dbcb0b7..fd9c7f7cf 100644 --- a/render/layout.c +++ b/render/layout.c @@ -4677,9 +4677,13 @@ bool layout_absolute(struct box *box, struct box *containing_block, if (!layout_block_context(box, -1, content)) return false; } else if (box->type == BOX_TABLE) { + /* layout_table also expects the containing block to be + * stored in the float_container field */ + box->float_container = containing_block; /* \todo layout_table considers margins etc. again */ if (!layout_table(box, width, content)) return false; + box->float_container = NULL; layout_solve_width(box, box->parent->width, box->width, 0, 0, -1, -1); } -- cgit v1.2.3