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

Unified Diff: third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp

Issue 2823003002: SkBitmap and SkPixelRef no longer need lock/unlock (Closed)
Patch Set: rebase Created 3 years, 8 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: third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp b/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp
index 7c14717bf9c7e8a97f51c05b3ccd98957ad3dacd..6a76f3be319f876385f728a64e6cc83004a2ba9a 100644
--- a/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp
+++ b/third_party/WebKit/Source/platform/graphics/paint/DrawingDisplayItem.cpp
@@ -76,8 +76,6 @@ static bool BitmapsEqual(sk_sp<const PaintRecord> record1,
SkBitmap bitmap1 = RecordToBitmap(record1);
SkBitmap bitmap2 = RecordToBitmap(record2);
- bitmap1.lockPixels();
- bitmap2.lockPixels();
int mismatch_count = 0;
const int kMaxMismatches = 10;
for (int y = 0; y < rect.height() && mismatch_count < kMaxMismatches; ++y) {
@@ -91,8 +89,6 @@ static bool BitmapsEqual(sk_sp<const PaintRecord> record1,
}
}
}
- bitmap1.unlockPixels();
- bitmap2.unlockPixels();
return !mismatch_count;
}

Powered by Google App Engine
This is Rietveld 408576698