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

Unified Diff: Source/platform/graphics/UnacceleratedImageBufferSurface.cpp

Issue 201213002: Remove uses of SkBitmap::Config (deprecated) from core/ and platform/. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 9 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/UnacceleratedImageBufferSurface.cpp
diff --git a/Source/platform/graphics/UnacceleratedImageBufferSurface.cpp b/Source/platform/graphics/UnacceleratedImageBufferSurface.cpp
index 40812df5e776038dbafc423a578370ea08678312..468576d35832492d755d23f524380f1d27a5b724 100644
--- a/Source/platform/graphics/UnacceleratedImageBufferSurface.cpp
+++ b/Source/platform/graphics/UnacceleratedImageBufferSurface.cpp
@@ -40,8 +40,7 @@ UnacceleratedImageBufferSurface::UnacceleratedImageBufferSurface(const IntSize&
: ImageBufferSurface(size, opacityMode)
{
SkBitmap bitmap;
- bitmap.setConfig(SkBitmap::kARGB_8888_Config, size.width(), size.height());
- bitmap.allocPixels();
+ bitmap.allocN32Pixels(size.width(), size.height());
reed1 2014/03/17 13:25:18 allocN32Pixels returns false on error, so you can
jbroman 2014/03/17 16:46:38 Done. Didn't realize SkCanvas::NewRasterN32 existe
if (bitmap.isNull())
return;
m_canvas = adoptPtr(new SkCanvas(bitmap));

Powered by Google App Engine
This is Rietveld 408576698