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

Unified Diff: Source/platform/graphics/paint/DisplayItemListTest.cpp

Issue 1220583004: Refactor DrawingRecorders to check for cached drawings earlier (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 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
« no previous file with comments | « Source/platform/graphics/GraphicsLayer.cpp ('k') | Source/platform/graphics/paint/DrawingRecorder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/paint/DisplayItemListTest.cpp
diff --git a/Source/platform/graphics/paint/DisplayItemListTest.cpp b/Source/platform/graphics/paint/DisplayItemListTest.cpp
index 212dfbf2fb9ced5ee5e2d1acbb0f3c7ca3fc3c40..b892d4f7fdd823540d4565596e9a307340bae8e9 100644
--- a/Source/platform/graphics/paint/DisplayItemListTest.cpp
+++ b/Source/platform/graphics/paint/DisplayItemListTest.cpp
@@ -84,11 +84,11 @@ public:
} \
} while (false);
-void drawRect(GraphicsContext& context, const TestDisplayItemClient& client, DisplayItem::Type type, const FloatRect& bound)
+void drawRect(GraphicsContext& context, const TestDisplayItemClient& client, DisplayItem::Type type, const FloatRect& bounds)
{
- DrawingRecorder drawingRecorder(context, client, type, bound);
- if (drawingRecorder.canUseCachedDrawing())
+ if (DrawingRecorder::useCachedDrawingIfPossible(context, client, type))
return;
+ DrawingRecorder drawingRecorder(context, client, type, bounds);
IntRect rect(0, 0, 10, 10);
context.drawRect(rect);
}
« no previous file with comments | « Source/platform/graphics/GraphicsLayer.cpp ('k') | Source/platform/graphics/paint/DrawingRecorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698