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

Unified Diff: src/animator/SkDisplayable.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/animator/SkDisplayXMLParser.cpp ('k') | src/animator/SkDraw3D.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/animator/SkDisplayable.cpp
diff --git a/src/animator/SkDisplayable.cpp b/src/animator/SkDisplayable.cpp
index 52532fedcd853ef459da25873c829e8fcfd512ea..dc3cecfdbae2aa25ccc41020979e7e169d45fde9 100644
--- a/src/animator/SkDisplayable.cpp
+++ b/src/animator/SkDisplayable.cpp
@@ -64,14 +64,14 @@ bool SkDisplayable::contains(SkDisplayable* ) {
}
SkDisplayable* SkDisplayable::contains(const SkString& ) {
- return NULL;
+ return nullptr;
}
SkDisplayable* SkDisplayable::deepCopy(SkAnimateMaker* maker) {
SkDisplayTypes type = getType();
if (type == SkType_Unknown) {
SkASSERT(0);
- return NULL;
+ return nullptr;
}
SkDisplayable* copy = SkDisplayType::CreateInstance(maker, type);
int index = -1;
@@ -79,7 +79,7 @@ SkDisplayable* SkDisplayable::deepCopy(SkAnimateMaker* maker) {
const SkMemberInfo* info;
do {
info = copy->getMember(++index);
- if (info == NULL)
+ if (info == nullptr)
break;
if (info->fType == SkType_MemberProperty) {
SkScriptValue value;
@@ -93,7 +93,7 @@ SkDisplayable* SkDisplayable::deepCopy(SkAnimateMaker* maker) {
if (info->fType == SkType_Array) {
SkTDOperandArray* array = (SkTDOperandArray*) info->memberData(this);
int arrayCount;
- if (array == NULL || (arrayCount = array->count()) == 0)
+ if (array == nullptr || (arrayCount = array->count()) == 0)
continue;
SkTDOperandArray* copyArray = (SkTDOperandArray*) info->memberData(copy);
copyArray->setCount(arrayCount);
@@ -110,7 +110,7 @@ SkDisplayable* SkDisplayable::deepCopy(SkAnimateMaker* maker) {
}
if (SkDisplayType::IsDisplayable(maker, info->fType)) {
SkDisplayable** displayable = (SkDisplayable**) info->memberData(this);
- if (*displayable == NULL || *displayable == (SkDisplayable*) -1)
+ if (*displayable == nullptr || *displayable == (SkDisplayable*) -1)
continue;
SkDisplayable* deeper = (*displayable)->deepCopy(maker);
info->setMemberData(copy, deeper, sizeof(deeper));
@@ -160,7 +160,7 @@ void SkDisplayable::dumpAttrs(SkAnimateMaker* maker) {
SkOperand blankValues[2];
do {
info = this->getMember(++index);
- if (NULL == info) {
+ if (nullptr == info) {
//SkDebugf("\n");
break;
}
@@ -185,7 +185,7 @@ void SkDisplayable::dumpAttrs(SkAnimateMaker* maker) {
if (info->fType == SkType_Array) {
SkTDOperandArray* array = (SkTDOperandArray*) info->memberData(this);
int arrayCount;
- if (array == NULL || (arrayCount = array->count()) == 0)
+ if (array == nullptr || (arrayCount = array->count()) == 0)
continue;
SkDisplayTypes elementType;
if (type == SkType_Array) {
@@ -259,12 +259,12 @@ void SkDisplayable::dumpChildren(SkAnimateMaker* maker, bool closedAngle) {
SkDisplayList::fIndent += 4;
do {
info = this->getMember(++index);
- if (NULL == info) {
+ if (nullptr == info) {
break;
}
if (SkDisplayType::IsDisplayable(maker, info->fType)) {
SkDisplayable** displayable = (SkDisplayable**) info->memberData(this);
- if (*displayable == NULL || *displayable == (SkDisplayable*) -1)
+ if (*displayable == nullptr || *displayable == (SkDisplayable*) -1)
continue;
if (closedAngle == false) {
SkDebugf(">\n");
@@ -422,21 +422,21 @@ void SkDisplayable::getBounds(SkRect* rect) {
}
const SkFunctionParamType* SkDisplayable::getFunctionsParameters() {
- return NULL;
+ return nullptr;
}
const SkMemberInfo* SkDisplayable::getMember(int index) {
- return NULL;
+ return nullptr;
}
const SkMemberInfo* SkDisplayable::getMember(const char name[]) {
- return NULL;
+ return nullptr;
}
const SkFunctionParamType* SkDisplayable::getParameters(const SkMemberInfo* info,
int* paramCount) {
const SkFunctionParamType* params = getFunctionsParameters();
- SkASSERT(params != NULL);
+ SkASSERT(params != nullptr);
int funcIndex = info->functionIndex();
// !!! eventually break traversing params into an external function (maybe this whole function)
int index = funcIndex;
@@ -456,7 +456,7 @@ const SkFunctionParamType* SkDisplayable::getParameters(const SkMemberInfo* info
}
SkDisplayable* SkDisplayable::getParent() const {
- return NULL;
+ return nullptr;
}
bool SkDisplayable::getProperty(int index, SkScriptValue* ) const {
@@ -484,7 +484,7 @@ bool SkDisplayable::isDrawable() const {
void SkDisplayable::onEndElement(SkAnimateMaker& ) {}
const SkMemberInfo* SkDisplayable::preferredChild(SkDisplayTypes type) {
- return NULL;
+ return nullptr;
}
bool SkDisplayable::resolveIDs(SkAnimateMaker& maker, SkDisplayable* original, SkApply* apply) {
« no previous file with comments | « src/animator/SkDisplayXMLParser.cpp ('k') | src/animator/SkDraw3D.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698