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

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

Issue 1419823005: Invalidate background-attachment:fixed on scroll. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2526
Patch Set: Created 5 years, 2 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 fa83feb98e79d33f2016f7367f745020d2ef1031..89fe6a7b87d7ff195695237ad2797ff35fb182d4 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -2494,7 +2494,7 @@ void LayoutObject::willBeDestroyed()
ResourceLoadPriorityOptimizer::resourceLoadPriorityOptimizer()->removeLayoutObject(this);
if (frameView())
- setIsSlowRepaintObject(false);
+ setIsBackgroundAttachmentFixedObject(false);
}
void LayoutObject::insertedIntoTree()
@@ -3396,16 +3396,16 @@ void LayoutObject::invalidatePaintIncludingNonSelfPaintingLayerDescendants(const
}
}
-void LayoutObject::setIsSlowRepaintObject(bool isSlowRepaintObject)
+void LayoutObject::setIsBackgroundAttachmentFixedObject(bool isBackgroundAttachmentFixedObject)
{
ASSERT(frameView());
- if (m_bitfields.isSlowRepaintObject() == isSlowRepaintObject)
+ if (m_bitfields.isBackgroundAttachmentFixedObject() == isBackgroundAttachmentFixedObject)
return;
- m_bitfields.setIsSlowRepaintObject(isSlowRepaintObject);
- if (isSlowRepaintObject)
- frameView()->addSlowRepaintObject();
+ m_bitfields.setIsBackgroundAttachmentFixedObject(isBackgroundAttachmentFixedObject);
+ if (isBackgroundAttachmentFixedObject)
+ frameView()->addBackgroundAttachmentFixedObject(this);
else
- frameView()->removeSlowRepaintObject();
+ frameView()->removeBackgroundAttachmentFixedObject(this);
}
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698