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

Unified Diff: third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.h

Issue 2184053003: Always fallback to checking bitmaps during under-invalidation checking (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - Created 4 years, 5 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/platform/graphics/paint/DrawingDisplayItem.h
diff --git a/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.h b/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.h
index b2aed26cadea437e4ba0962d07a4ba658122e0fe..310a9739994f8f9a10ab2ec0998cafd0d8ace289 100644
--- a/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.h
+++ b/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.h
@@ -15,29 +15,12 @@ namespace blink {
class PLATFORM_EXPORT DrawingDisplayItem final : public DisplayItem {
public:
-#if ENABLE(ASSERT)
- enum UnderInvalidationCheckingMode {
- CheckPicture, // Check if the new picture and the old picture are the same
- CheckBitmap, // Check if the new picture and the old picture produce the same bitmap
- };
-#endif
-
- DrawingDisplayItem(const DisplayItemClient& client
- , Type type
- , PassRefPtr<const SkPicture> picture
- , bool knownToBeOpaque = false
-#if ENABLE(ASSERT)
- , UnderInvalidationCheckingMode underInvalidationCheckingMode = CheckPicture
-#endif
- )
+ DrawingDisplayItem(const DisplayItemClient& client, Type type, PassRefPtr<const SkPicture> picture, bool knownToBeOpaque = false)
: DisplayItem(client, type, sizeof(*this))
, m_picture(picture && picture->approximateOpCount() ? picture : nullptr)
, m_knownToBeOpaque(knownToBeOpaque)
-#if ENABLE(ASSERT)
- , m_underInvalidationCheckingMode(underInvalidationCheckingMode)
-#endif
{
- ASSERT(isDrawingType(type));
+ DCHECK(isDrawingType(type));
}
void replay(GraphicsContext&) const override;
@@ -46,12 +29,11 @@ public:
const SkPicture* picture() const { return m_picture.get(); }
- bool knownToBeOpaque() const { ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); return m_knownToBeOpaque; }
+ bool knownToBeOpaque() const { DCHECK(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); return m_knownToBeOpaque; }
void analyzeForGpuRasterization(SkPictureGpuAnalyzer&) const override;
-#if ENABLE(ASSERT)
- UnderInvalidationCheckingMode getUnderInvalidationCheckingMode() const { return m_underInvalidationCheckingMode; }
+#if DCHECK_IS_ON()
bool equals(const DisplayItem& other) const final;
#endif
@@ -64,10 +46,6 @@ private:
// True if there are no transparent areas. Only used for SlimmingPaintV2.
const bool m_knownToBeOpaque;
-
-#if ENABLE(ASSERT)
- UnderInvalidationCheckingMode m_underInvalidationCheckingMode;
-#endif
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698