Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/4b6967fee487262d73aca83226647b5d428f5e6d
...commit
http://git.netsurf-browser.org/netsurf.git/commit/4b6967fee487262d73aca83226647b5d428f5e6d
...tree
http://git.netsurf-browser.org/netsurf.git/tree/4b6967fee487262d73aca83226647b5d428f5e6d
The branch, master has been updated
via 4b6967fee487262d73aca83226647b5d428f5e6d (commit)
from 5ee910ffee2763e75805a61c8e9e69841d0932b0 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=4b6967fee487262d73aca83226647b5d428f5e6d
commit 4b6967fee487262d73aca83226647b5d428f5e6d
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
Layout: Apply min/max width to replaced elements when width is given.
diff --git a/content/handlers/html/layout.c b/content/handlers/html/layout.c
index f4a1a20..611c778 100644
--- a/content/handlers/html/layout.c
+++ b/content/handlers/html/layout.c
@@ -220,6 +220,11 @@ layout_get_object_dimensions(struct box *box,
int intrinsic_width = content_get_width(box->object);
int intrinsic_height = content_get_height(box->object);
+ if (min_width > 0 && min_width > *width)
+ *width = min_width;
+ if (max_width >= 0 && max_width < *width)
+ *width = max_width;
+
if (intrinsic_width != 0)
*height = (*width * intrinsic_height) /
intrinsic_width;
-----------------------------------------------------------------------
Summary of changes:
content/handlers/html/layout.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/content/handlers/html/layout.c b/content/handlers/html/layout.c
index f4a1a20..611c778 100644
--- a/content/handlers/html/layout.c
+++ b/content/handlers/html/layout.c
@@ -220,6 +220,11 @@ layout_get_object_dimensions(struct box *box,
int intrinsic_width = content_get_width(box->object);
int intrinsic_height = content_get_height(box->object);
+ if (min_width > 0 && min_width > *width)
+ *width = min_width;
+ if (max_width >= 0 && max_width < *width)
+ *width = max_width;
+
if (intrinsic_width != 0)
*height = (*width * intrinsic_height) /
intrinsic_width;
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org