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

Unified Diff: skia/ext/bitmap_platform_device_win.cc

Issue 1839113002: Limit manual control of platform painting (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Privatize Created 4 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
« no previous file with comments | « skia/ext/bitmap_platform_device_win.h ('k') | skia/ext/platform_canvas.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/bitmap_platform_device_win.cc
diff --git a/skia/ext/bitmap_platform_device_win.cc b/skia/ext/bitmap_platform_device_win.cc
index d9cf3884e307a35e17e8f029d2ccfeeac004b9df..6602cc1bcb64991fbb9e17565871e6eb2570e89f 100644
--- a/skia/ext/bitmap_platform_device_win.cc
+++ b/skia/ext/bitmap_platform_device_win.cc
@@ -200,7 +200,6 @@ BitmapPlatformDevice::BitmapPlatformDevice(
config_dirty_(true), // Want to load the config next time.
transform_(SkMatrix::I()) {
// The data object is already ref'ed for us by create().
- SkDEBUGCODE(begin_paint_count_ = 0);
if (hbitmap) {
SetPlatformDevice(this, this);
// Initialize the clip region to the entire bitmap.
@@ -214,21 +213,14 @@ BitmapPlatformDevice::BitmapPlatformDevice(
}
BitmapPlatformDevice::~BitmapPlatformDevice() {
- SkASSERT(begin_paint_count_ == 0);
if (hdc_)
ReleaseBitmapDC();
}
HDC BitmapPlatformDevice::BeginPlatformPaint() {
- SkDEBUGCODE(begin_paint_count_++);
return GetBitmapDC();
}
-void BitmapPlatformDevice::EndPlatformPaint() {
- SkASSERT(begin_paint_count_--);
- PlatformDevice::EndPlatformPaint();
-}
-
void BitmapPlatformDevice::setMatrixClip(const SkMatrix& transform,
const SkRegion& region,
const SkClipStack&) {
@@ -285,7 +277,6 @@ void BitmapPlatformDevice::DrawToHDC(HDC dc, int x, int y,
}
LoadTransformToDC(source_dc, transform_);
- EndPlatformPaint();
if (created_dc)
ReleaseBitmapDC();
}
« no previous file with comments | « skia/ext/bitmap_platform_device_win.h ('k') | skia/ext/platform_canvas.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698