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

Unified Diff: third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp

Issue 2523673004: [NOT FOR COMMIT] Fully replace SkCanvas uses.
Patch Set: Support Android build. Created 4 years 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/modules/csspaint/PaintRenderingContext2D.cpp
diff --git a/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp b/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp
index 5b8f3bfb5b70f968fdeec567297916bbc9f230a2..ad4556ace06ce34621903db75caabdd07e66cd2d 100644
--- a/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp
+++ b/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp
@@ -4,6 +4,7 @@
#include "modules/csspaint/PaintRenderingContext2D.h"
+#include "skia/ext/cdl_canvas.h"
#include "platform/graphics/ImageBuffer.h"
#include <memory>
@@ -47,11 +48,11 @@ bool PaintRenderingContext2D::parseColorOrCurrentColor(
return ::blink::parseColorOrCurrentColor(color, colorString, nullptr);
}
-SkCanvas* PaintRenderingContext2D::drawingCanvas() const {
+CdlCanvas* PaintRenderingContext2D::drawingCanvas() const {
return m_imageBuffer->canvas();
}
-SkCanvas* PaintRenderingContext2D::existingDrawingCanvas() const {
+CdlCanvas* PaintRenderingContext2D::existingDrawingCanvas() const {
ASSERT(m_imageBuffer);
return m_imageBuffer->canvas();
}
@@ -68,7 +69,7 @@ void PaintRenderingContext2D::didDraw(const SkIRect& dirtyRect) {
void PaintRenderingContext2D::validateStateStack() const {
#if DCHECK_IS_ON()
- if (SkCanvas* skCanvas = existingDrawingCanvas()) {
+ if (CdlCanvas* skCanvas = existingDrawingCanvas()) {
DCHECK_EQ(static_cast<size_t>(skCanvas->getSaveCount()),
m_stateStack.size() + 1);
}

Powered by Google App Engine
This is Rietveld 408576698