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

Unified Diff: Source/platform/graphics/paint/DisplayItemList.h

Issue 1160763005: Don't cache reflection drawings (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix win (which doesn't pack bool bitfields) Created 5 years, 7 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: Source/platform/graphics/paint/DisplayItemList.h
diff --git a/Source/platform/graphics/paint/DisplayItemList.h b/Source/platform/graphics/paint/DisplayItemList.h
index 57a8074405c34b1d845002801560a3147516d1a6..319d7f5cd8f415b66a53f2d6f698d13689791902 100644
--- a/Source/platform/graphics/paint/DisplayItemList.h
+++ b/Source/platform/graphics/paint/DisplayItemList.h
@@ -35,6 +35,10 @@ public:
void beginScope(DisplayItemClient);
void endScope(DisplayItemClient);
+ void beginSkippingCache() { ++m_skippingCacheCount; }
+ void endSkippingCache() { ASSERT(m_skippingCacheCount > 0); --m_skippingCacheCount; }
+ bool skippingCache() const { return m_skippingCacheCount; }
+
// Must be called when a painting is finished.
void commitNewDisplayItems();
@@ -64,7 +68,8 @@ public:
protected:
DisplayItemList()
: m_validlyCachedClientsDirty(false)
- , m_constructionDisabled(false) { }
+ , m_constructionDisabled(false)
+ , m_skippingCacheCount(0) { }
private:
friend class DisplayItemListTest;
@@ -109,6 +114,8 @@ private:
// in performance metrics.
bool m_constructionDisabled;
+ int m_skippingCacheCount;
+
// Scope ids are allocated per client to ensure that the ids are stable for non-invalidated
// clients between frames, so that we can use the id to match new display items to cached
// display items.
« no previous file with comments | « Source/platform/graphics/paint/DisplayItemCacheSkipper.h ('k') | Source/platform/graphics/paint/DisplayItemList.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698