<svg> fails to use explicit width and height inside <html> inside IFRAME
authorleviw@chromium.org <leviw@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 24 Oct 2011 18:56:16 +0000 (18:56 +0000)
committerleviw@chromium.org <leviw@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 24 Oct 2011 18:56:16 +0000 (18:56 +0000)
commitf909d9bf980f078ff58f2aa1b4056d49800226dc
tree4e69cd61faf5a0cfa148698bec6854e0d8a93d44
parentf1d579e97d6c4c4e29e181dd2408fffd7224e635
<svg> fails to use explicit width and height inside <html> inside IFRAME
https://bugs.webkit.org/show_bug.cgi?id=64823

Reviewed by Nikolas Zimmermann.

Source/WebCore:

Checking that embedded SVG is in an SVG document before negotiating size
with the host document.

Test: svg/as-object/svg-embedded-in-html-in-iframe.html

* rendering/svg/RenderSVGRoot.cpp:
(WebCore::isEmbeddedThroughFrameContainingSVGDocument):
(WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
(WebCore::RenderSVGRoot::computeReplacedLogicalHeight):

LayoutTests:

Fixing a bug where SVG negotiated size when embedded in html inside an iframe.

* platform/chromium/test_expectations.txt: Will update with results on other platforms.
* platform/mac/svg/as-object/svg-embedded-in-html-in-iframe-expected.png: Added.
* platform/mac/svg/as-object/svg-embedded-in-html-in-iframe-expected.txt: Added.
* svg/as-object/svg-embedded-in-html-in-iframe.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@98263 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/platform/chromium/test_expectations.txt
LayoutTests/platform/mac/svg/as-object/svg-embedded-in-html-in-iframe-expected.png [new file with mode: 0644]
LayoutTests/platform/mac/svg/as-object/svg-embedded-in-html-in-iframe-expected.txt [new file with mode: 0644]
LayoutTests/svg/as-object/svg-embedded-in-html-in-iframe.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/svg/RenderSVGRoot.cpp