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

Unified Diff: debugger/QT/SkRasterWidget.cpp

Issue 322963002: hide SkBitmap::setConfig (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 6 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 | « bench/TileBench.cpp ('k') | experimental/PdfViewer/chop_transparency_main.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: debugger/QT/SkRasterWidget.cpp
diff --git a/debugger/QT/SkRasterWidget.cpp b/debugger/QT/SkRasterWidget.cpp
index d78e5f85591e8e55d74f4b37e0e981f837ff87d2..705fdf0bd853c7d8b6237efd182dad7c60124ba3 100644
--- a/debugger/QT/SkRasterWidget.cpp
+++ b/debugger/QT/SkRasterWidget.cpp
@@ -9,8 +9,7 @@
#include "SkRasterWidget.h"
SkRasterWidget::SkRasterWidget(SkDebugger *debugger) : QWidget() {
- fBitmap.setConfig(SkBitmap::kARGB_8888_Config, 800, 800);
- fBitmap.allocPixels();
+ fBitmap.allocN32Pixels(800, 800);
fBitmap.eraseColor(SK_ColorTRANSPARENT);
fDevice = new SkBitmapDevice(fBitmap);
fDebugger = debugger;
@@ -24,8 +23,7 @@ SkRasterWidget::~SkRasterWidget() {
}
void SkRasterWidget::resizeEvent(QResizeEvent* event) {
- fBitmap.setConfig(SkBitmap::kARGB_8888_Config, event->size().width(), event->size().height());
- fBitmap.allocPixels();
+ fBitmap.allocN32Pixels(event->size().width(), event->size().height());
fBitmap.eraseColor(SK_ColorTRANSPARENT);
SkSafeUnref(fCanvas);
SkSafeUnref(fDevice);
« no previous file with comments | « bench/TileBench.cpp ('k') | experimental/PdfViewer/chop_transparency_main.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698