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

Unified Diff: src/utils/win/SkDWriteFontFileStream.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 | « src/utils/win/SkDWrite.cpp ('k') | src/utils/win/SkDWriteGeometrySink.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/win/SkDWriteFontFileStream.cpp
diff --git a/src/utils/win/SkDWriteFontFileStream.cpp b/src/utils/win/SkDWriteFontFileStream.cpp
index eb7e5dccafdf3be0ece722892cf823cfe9678629..0e3d4fc20246c5823bf0ba3c49b206e5d950dfbb 100644
--- a/src/utils/win/SkDWriteFontFileStream.cpp
+++ b/src/utils/win/SkDWriteFontFileStream.cpp
@@ -20,8 +20,8 @@
SkDWriteFontFileStream::SkDWriteFontFileStream(IDWriteFontFileStream* fontFileStream)
: fFontFileStream(SkRefComPtr(fontFileStream))
, fPos(0)
- , fLockedMemory(NULL)
- , fFragmentLock(NULL) {
+ , fLockedMemory(nullptr)
+ , fFragmentLock(nullptr) {
}
SkDWriteFontFileStream::~SkDWriteFontFileStream() {
@@ -33,7 +33,7 @@ SkDWriteFontFileStream::~SkDWriteFontFileStream() {
size_t SkDWriteFontFileStream::read(void* buffer, size_t size) {
HRESULT hr = S_OK;
- if (NULL == buffer) {
+ if (nullptr == buffer) {
size_t fileSize = this->getLength();
if (fPos + size > fileSize) {
@@ -137,7 +137,7 @@ HRESULT SkDWriteFontFileStreamWrapper::Create(SkStreamAsset* stream,
SkDWriteFontFileStreamWrapper** streamFontFileStream)
{
*streamFontFileStream = new SkDWriteFontFileStreamWrapper(stream);
- if (NULL == streamFontFileStream) {
+ if (nullptr == streamFontFileStream) {
return E_OUTOFMEMORY;
}
return S_OK;
@@ -153,7 +153,7 @@ HRESULT STDMETHODCALLTYPE SkDWriteFontFileStreamWrapper::QueryInterface(REFIID i
AddRef();
return S_OK;
} else {
- *ppvObject = NULL;
+ *ppvObject = nullptr;
return E_NOINTERFACE;
}
}
@@ -180,8 +180,8 @@ HRESULT STDMETHODCALLTYPE SkDWriteFontFileStreamWrapper::ReadFileFragment(
UINT64 fileSize;
this->GetFileSize(&fileSize);
if (fileOffset > fileSize || fragmentSize > fileSize - fileOffset) {
- *fragmentStart = NULL;
- *fragmentContext = NULL;
+ *fragmentStart = nullptr;
+ *fragmentContext = nullptr;
return E_FAIL;
}
@@ -192,14 +192,14 @@ HRESULT STDMETHODCALLTYPE SkDWriteFontFileStreamWrapper::ReadFileFragment(
const void* data = fStream->getMemoryBase();
if (data) {
*fragmentStart = static_cast<BYTE const*>(data) + static_cast<size_t>(fileOffset);
- *fragmentContext = NULL;
+ *fragmentContext = nullptr;
} else {
// May be called from multiple threads.
SkAutoMutexAcquire ama(fStreamMutex);
- *fragmentStart = NULL;
- *fragmentContext = NULL;
+ *fragmentStart = nullptr;
+ *fragmentContext = nullptr;
if (!fStream->seek(static_cast<size_t>(fileOffset))) {
return E_FAIL;
« no previous file with comments | « src/utils/win/SkDWrite.cpp ('k') | src/utils/win/SkDWriteGeometrySink.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698