Use fixed insted of floating point to get percentage of available_width, for width calc.

svn path=/trunk/netsurf/; revision=12869
This commit is contained in:
Michael Drake 2011-09-23 16:50:20 +00:00
parent e4a91f380c
commit dcfd80956f

View File

@ -1527,8 +1527,8 @@ void layout_find_dimensions(int available_width, int viewport_height,
if (wtype == CSS_WIDTH_SET) {
if (unit == CSS_UNIT_PCT) {
*width = (FIXTOFLT(value) * available_width)
/ 100;
*width = FPCT_OF_INT_TOINT(
value, available_width);
} else {
*width = FIXTOINT(nscss_len2px(value, unit,
style));