100% height elements to not respond to vertical browser rescaling
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 21:15:46 +0000 (21:15 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 21:15:46 +0000 (21:15 +0000)
commita276788a59332e5132797de970b38374f4adb871
tree52c1e1e949ec839d27a93d96ebc7cb886b925b73
parent35ec78afcb0eb0cbe5749be01f0c58c69e8c4c0e
100% height elements to not respond to vertical browser rescaling
https://bugs.webkit.org/show_bug.cgi?id=43022

Patch by Terry Anderson <tdanderson@chromium.org> on 2012-03-16
Reviewed by Julien Chaffraix.

Source/WebCore:

Test: fast/replaced/vertical-resize-100percent-element.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeReplacedLogicalHeightUsing):
    For the case where a replaced element has a percentage height,
    we update the entries in RenderBlock::gPercentHeightDescendantsMap
    corresponding to all ancestors of the replaced element.

LayoutTests:

* fast/replaced/resources/vertical-resize-100percent-contents.html: Added.
* fast/replaced/vertical-resize-100percent-element-expected.txt: Added.
* fast/replaced/vertical-resize-100percent-element.html: Added.
      Layout test to ensure that an image with 100% height is resized when
      its containing iframe is vertically resized to be larger or smaller.
* platform/chromium-linux/tables/mozilla_expected_failures/bugs/bug85016-expected.png:
* platform/chromium-win/tables/mozilla_expected_failures/bugs/bug85016-expected.txt:
      Rebaseline for chromium. This patch causes a progression in this layout test.  In the
      diff, note that the viewport has height 585, which is 600 minus 15 pixels to account for
      the horizontal scrollbar.  In the old expected output the first image to be displayed
      has height 600, which is incorrect because it should be 100% of the viewport height.
      The new expected output shows the first image with the correct height of 585.
* platform/chromium/test_expectations.txt:
      WIN will need a regenerated image, and MAC will need a regenerated image+text.
* platform/gtk/Skipped:
* platform/mac/Skipped:
* platform/qt/Skipped:
* platform/win/Skipped:
      Skip the rebaselined test on all other platforms.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@111064 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/replaced/resources/vertical-resize-100percent-contents.html [new file with mode: 0644]
LayoutTests/fast/replaced/vertical-resize-100percent-element-expected.txt [new file with mode: 0644]
LayoutTests/fast/replaced/vertical-resize-100percent-element.html [new file with mode: 0644]
LayoutTests/platform/chromium-linux/tables/mozilla_expected_failures/bugs/bug85016-expected.png
LayoutTests/platform/chromium-win/tables/mozilla_expected_failures/bugs/bug85016-expected.txt
LayoutTests/platform/chromium/test_expectations.txt
LayoutTests/platform/gtk/Skipped
LayoutTests/platform/mac/Skipped
LayoutTests/platform/qt/Skipped
LayoutTests/platform/win/Skipped
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderBox.cpp