Bad rendering of web page because of image's height is set to 100%
https://bugs.webkit.org/show_bug.cgi?id=28035
Reviewed by Eric Seidel.
Source/WebCore:
Call computeReplacedLogicalHeight() to get the correct logical height of a replaced element
for calculating the element's width. RenderBox::computeLogicalHeightUsing() is a helper function designed for finding
the min and max height values and is not the way to find the actual used height of a replaced element.
WebKit's quirks-mode behaviour for the test case is unaffected by this change.
Tests: fast/css/computed-image-width-with-percent-height-quirksmode.html
fast/css/computed-image-width-with-percent-height.html
* rendering/RenderReplaced.cpp:
(WebCore::RenderReplaced::computeReplacedLogicalWidth):
LayoutTests:
* fast/css/computed-image-width-with-percent-height-expected.html: Added.
* fast/css/computed-image-width-with-percent-height-quirksmode-expected.html: Added.
* fast/css/computed-image-width-with-percent-height-quirksmode.html: Added.
* fast/css/computed-image-width-with-percent-height.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@136347 268f45cc-cd09-0410-ab3c-d52691b4dbfc
7 files changed