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

Unified Diff: third_party/WebKit/Source/core/paint/PaintLayer.cpp

Issue 2181953004: Changed ComputedStyle's EVisibility to be an enum class and fixed naming (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_move_computedstyle_around
Patch Set: Rebase Created 4 years, 4 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/paint/PaintLayer.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintLayer.cpp b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
index 956ad36ddd948cd03c85d7a82ed7ab047681f650..23c1b04d6cecad50eb4b35f4c27b992bf514c703 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayer.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintLayer.cpp
@@ -176,7 +176,7 @@ PaintLayer::PaintLayer(LayoutBoxModelObject* layoutObject)
if (!layoutObject->slowFirstChild() && layoutObject->style()) {
m_visibleContentStatusDirty = false;
- m_hasVisibleContent = layoutObject->style()->visibility() == VISIBLE;
+ m_hasVisibleContent = layoutObject->style()->visibility() == EVisibility::Visible;
}
updateScrollableArea();
@@ -612,7 +612,7 @@ void PaintLayer::potentiallyDirtyVisibleContentStatus(EVisibility visibility)
{
if (m_visibleContentStatusDirty)
return;
- if (hasVisibleContent() == (visibility == VISIBLE))
+ if (hasVisibleContent() == (visibility == EVisibility::Visible))
return;
dirtyVisibleContentStatus();
}
@@ -673,14 +673,14 @@ void PaintLayer::updateDescendantDependentFlags()
if (m_visibleContentStatusDirty) {
bool previouslyHasVisibleContent = m_hasVisibleContent;
- if (layoutObject()->style()->visibility() == VISIBLE) {
+ if (layoutObject()->style()->visibility() == EVisibility::Visible) {
m_hasVisibleContent = true;
} else {
// layer may be hidden but still have some visible content, check for this
m_hasVisibleContent = false;
LayoutObject* r = layoutObject()->slowFirstChild();
while (r) {
- if (r->style()->visibility() == VISIBLE && (!r->hasLayer() || !r->enclosingLayer()->isSelfPaintingLayer())) {
+ if (r->style()->visibility() == EVisibility::Visible && (!r->hasLayer() || !r->enclosingLayer()->isSelfPaintingLayer())) {
m_hasVisibleContent = true;
break;
}
@@ -1214,7 +1214,7 @@ PaintLayer* PaintLayer::removeChild(PaintLayer* oldChild)
oldChild->stackingNode()->dirtyStackingContextZOrderLists();
}
- if (layoutObject()->style()->visibility() != VISIBLE)
+ if (layoutObject()->style()->visibility() != EVisibility::Visible)
dirtyVisibleContentStatus();
oldChild->setPreviousSibling(0);
@@ -2391,7 +2391,7 @@ bool PaintLayer::backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect)
// We can't use hasVisibleContent(), because that will be true if our layoutObject is hidden, but some child
// is visible and that child doesn't cover the entire rect.
- if (layoutObject()->style()->visibility() != VISIBLE)
+ if (layoutObject()->style()->visibility() != EVisibility::Visible)
return false;
if (paintsWithFilters() && layoutObject()->style()->filter().hasFilterThatAffectsOpacity())

Powered by Google App Engine
This is Rietveld 408576698