Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(339)

Unified Diff: Source/core/frame/FrameView.cpp

Issue 277563004: [SVG2] overflow should be ignored in img and background-image. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: add comment Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/svg/as-image/resources/overflow-hidden.svg ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 933b6334b49e76debebafeb36a08a2413c478a94..44e2b346d592126fc6ff2e23e22809a379a9e2df 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -533,6 +533,10 @@ void FrameView::applyOverflowToViewportAndSetRenderer(RenderObject* o, Scrollbar
EOverflow overflowY = o->style()->overflowY();
if (o->isSVGRoot()) {
+ // Don't allow overflow to affect <img> and css backgrounds
+ if (toRenderSVGRoot(o)->isEmbeddedThroughSVGImage())
+ return;
+
// FIXME: evaluate if we can allow overflow for these cases too.
// Overflow is always hidden when stand-alone SVG documents are embedded.
if (toRenderSVGRoot(o)->isEmbeddedThroughFrameContainingSVGDocument()) {
« no previous file with comments | « LayoutTests/svg/as-image/resources/overflow-hidden.svg ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698