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

Unified Diff: tests/PixelRefTest.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 years, 4 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 | « tests/PictureTest.cpp ('k') | tests/PointTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/PixelRefTest.cpp
diff --git a/tests/PixelRefTest.cpp b/tests/PixelRefTest.cpp
index 775354c83d865dc60b3eb3f1d041b392f44770a4..01e2ce5c0bd21bdb3f98b960e57f1d51aa4b02ba 100644
--- a/tests/PixelRefTest.cpp
+++ b/tests/PixelRefTest.cpp
@@ -23,21 +23,21 @@ static void test_dont_leak_install(skiatest::Reporter* reporter) {
info = SkImageInfo::MakeN32Premul(0, 0);
release_counter = 1;
- success = bm.installPixels(info, NULL, 0, NULL, decrement_counter_proc, &release_counter);
+ success = bm.installPixels(info, nullptr, 0, nullptr, decrement_counter_proc, &release_counter);
REPORTER_ASSERT(reporter, true == success);
bm.reset();
REPORTER_ASSERT(reporter, 0 == release_counter);
info = SkImageInfo::MakeN32Premul(10, 10);
release_counter = 1;
- success = bm.installPixels(info, NULL, 0, NULL, decrement_counter_proc, &release_counter);
+ success = bm.installPixels(info, nullptr, 0, nullptr, decrement_counter_proc, &release_counter);
REPORTER_ASSERT(reporter, true == success);
bm.reset();
REPORTER_ASSERT(reporter, 0 == release_counter);
info = SkImageInfo::MakeN32Premul(-10, -10);
release_counter = 1;
- success = bm.installPixels(info, NULL, 0, NULL, decrement_counter_proc, &release_counter);
+ success = bm.installPixels(info, nullptr, 0, nullptr, decrement_counter_proc, &release_counter);
REPORTER_ASSERT(reporter, false == success);
bm.reset();
REPORTER_ASSERT(reporter, 0 == release_counter);
@@ -48,12 +48,12 @@ static void test_install(skiatest::Reporter* reporter) {
SkImageInfo info = SkImageInfo::MakeN32Premul(0, 0);
SkBitmap bm;
// make sure we don't assert on an empty install
- success = bm.installPixels(info, NULL, 0);
+ success = bm.installPixels(info, nullptr, 0);
REPORTER_ASSERT(reporter, success);
// no pixels should be the same as setInfo()
info = SkImageInfo::MakeN32Premul(10, 10);
- success = bm.installPixels(info, NULL, 0);
+ success = bm.installPixels(info, nullptr, 0);
REPORTER_ASSERT(reporter, success);
}
@@ -69,7 +69,7 @@ private:
DEF_TEST(PixelRef_GenIDChange, r) {
SkImageInfo info = SkImageInfo::MakeN32Premul(10, 10);
- SkAutoTUnref<SkPixelRef> pixelRef(SkMallocPixelRef::NewAllocate(info, 0, NULL));
+ SkAutoTUnref<SkPixelRef> pixelRef(SkMallocPixelRef::NewAllocate(info, 0, nullptr));
// Register a listener.
int count = 0;
@@ -94,9 +94,9 @@ DEF_TEST(PixelRef_GenIDChange, r) {
pixelRef->notifyPixelsChanged();
REPORTER_ASSERT(r, 1 == count);
- // Quick check that NULL is safe.
+ // Quick check that nullptr is safe.
REPORTER_ASSERT(r, 0 != pixelRef->getGenerationID());
- pixelRef->addGenIDChangeListener(NULL);
+ pixelRef->addGenIDChangeListener(nullptr);
pixelRef->notifyPixelsChanged();
test_install(r);
« no previous file with comments | « tests/PictureTest.cpp ('k') | tests/PointTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698