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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutObject.cpp

Issue 2684833003: Disable display: contents in SVG. (Closed)
Patch Set: Make display: contents act as an inline when it has a layout box, and ignore display: contents in S… Created 3 years, 10 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
Index: third_party/WebKit/Source/core/layout/LayoutObject.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.cpp b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
index 59481168c6b51d0c2b527e6ed4771f5c0aa0e833..83ddbac407f026c4962601903fd6f71345caae1d 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -178,7 +178,9 @@ LayoutObject* LayoutObject::createObject(Element* element,
switch (style.display()) {
case EDisplay::None:
+ return nullptr;
case EDisplay::Contents:
+ DCHECK(!element->isSVGElement());
return nullptr;
case EDisplay::Inline:
return new LayoutInline(element);

Powered by Google App Engine
This is Rietveld 408576698