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

Unified Diff: third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.h

Issue 1393083003: Implement interest rects for synchronized paint. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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/compositing/CompositedLayerMapping.h
diff --git a/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.h b/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.h
index fa6de6c794c627484f677b54e027ac1b1481b168..d9013d2f8645ce092bc8f2f9b8f10e8ff957dc2f 100644
--- a/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.h
+++ b/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.h
@@ -68,7 +68,7 @@ enum GraphicsLayerUpdateScope {
//
// Currently (Oct. 2013) there is one CompositedLayerMapping for each Layer,
// but this is likely to evolve soon.
-class CompositedLayerMapping final : public GraphicsLayerClient {
+class PLATFORM_EXPORT CompositedLayerMapping final : public GraphicsLayerClient {
chrishtr 2015/10/09 19:10:29 This is needed to expose the class for testing acr
WTF_MAKE_NONCOPYABLE(CompositedLayerMapping); WTF_MAKE_FAST_ALLOCATED(CompositedPaintLayerMapping);
public:
explicit CompositedLayerMapping(PaintLayer&);
@@ -147,7 +147,9 @@ public:
// GraphicsLayerClient interface
void notifyAnimationStarted(const GraphicsLayer*, double monotonicTime, int group) override;
void notifyTextPainted() override;
+
void paintContents(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase, const IntRect& clip) const override;
+ void paintContentsIfNeeded(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase) const override;
bool isTrackingPaintInvalidations() const override;
#if ENABLE(ASSERT)
@@ -205,6 +207,8 @@ public:
String debugName() const { return "CompositedLayerMapping for " + owningLayer().debugName(); }
private:
+ static IntRect computeInterestRect(const GraphicsLayer*, LayoutObject* owningLayoutObject);
+
static const GraphicsLayerPaintInfo* containingSquashedLayer(const LayoutObject*, const Vector<GraphicsLayerPaintInfo>& layers, unsigned maxSquashedLayerIndex);
// Helper methods to updateGraphicsLayerGeometry:
@@ -428,6 +432,8 @@ private:
unsigned m_backgroundLayerPaintsFixedRootBackground : 1;
unsigned m_scrollingContentsAreEmpty : 1;
+
+ friend class CompositedLayerMappingTest;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698