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

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

Issue 2727853002: [css-display] Support display: contents pseudo-elements.
Patch Set: [css-display] Support display: contents pseudos. Created 3 years, 9 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 2fbf31901394b4a51cd540abc83dfd497dca7ab5..2164e68e01d9cb17e86b383a780deda261282715 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -35,6 +35,7 @@
#include "core/css/resolver/StyleResolver.h"
#include "core/dom/AXObjectCache.h"
#include "core/dom/ElementTraversal.h"
+#include "core/dom/PseudoElement.h"
#include "core/dom/StyleChangeReason.h"
#include "core/dom/StyleEngine.h"
#include "core/dom/shadow/ShadowRoot.h"
@@ -1588,6 +1589,11 @@ void LayoutObject::setPseudoStyle(PassRefPtr<ComputedStyle> pseudoStyle) {
setStyle(std::move(pseudoStyle));
}
+bool LayoutObject::isPseudoElementGeneratedContentFor(
+ const PseudoElement& pseudo) const {
+ return isAnonymous() && m_node.get() == &pseudo;
+}
+
void LayoutObject::firstLineStyleDidChange(const ComputedStyle& oldStyle,
const ComputedStyle& newStyle) {
StyleDifference diff = oldStyle.visualInvalidationDiff(newStyle);

Powered by Google App Engine
This is Rietveld 408576698