aboutsummaryrefslogtreecommitdiffhomepage
path: root/samplecode/SampleLua.cpp
diff options
context:
space:
mode:
authorGravatar halcanary <halcanary@google.com>2015-08-27 07:41:13 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-08-27 07:41:16 -0700
commit96fcdcc219d2a0d3579719b84b28bede76efba64 (patch)
tree0ec5ea0193d8292df8bf5ed9dd8498a5eb5763dd /samplecode/SampleLua.cpp
parent435af2f736c85c3274a0c6760a3523810750d237 (diff)
Style Change: NULL->nullptr
Diffstat (limited to 'samplecode/SampleLua.cpp')
-rw-r--r--samplecode/SampleLua.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/samplecode/SampleLua.cpp b/samplecode/SampleLua.cpp
index 5fc9ab0c78..96b15b91b8 100644
--- a/samplecode/SampleLua.cpp
+++ b/samplecode/SampleLua.cpp
@@ -39,7 +39,7 @@ static const char gMissingCode[] = ""
class LuaView : public SampleView {
public:
- LuaView() : fLua(NULL) {}
+ LuaView() : fLua(nullptr) {}
virtual ~LuaView() { delete fLua; }
@@ -56,7 +56,7 @@ public:
}
lua_State* ensureLua() {
- if (NULL == fLua) {
+ if (nullptr == fLua) {
fLua = new SkLua;
SkString str = GetResourcePath(LUA_FILENAME);
@@ -90,7 +90,7 @@ protected:
SkDebugf("lua err: %s\n", lua_tostring(L, -1));
} else {
if (lua_isboolean(L, -1) && lua_toboolean(L, -1)) {
- this->inval(NULL);
+ this->inval(nullptr);
return true;
}
}
@@ -117,7 +117,7 @@ protected:
SkDebugf("lua err: %s\n", lua_tostring(L, -1));
} else {
if (lua_isboolean(L, -1) && lua_toboolean(L, -1)) {
- this->inval(NULL);
+ this->inval(nullptr);
}
}
}
@@ -135,7 +135,7 @@ protected:
SkDebugf("lua err: %s\n", lua_tostring(L, -1));
} else {
if (lua_isboolean(L, -1) && lua_toboolean(L, -1)) {
- this->inval(NULL);
+ this->inval(nullptr);
Click* c = new Click(this);
c->setType(gLuaClickHandlerName);
return c;
@@ -150,7 +150,7 @@ protected:
return this->INHERITED::onClick(click);
}
- const char* state = NULL;
+ const char* state = nullptr;
switch (click->fState) {
case Click::kMoved_State:
state = "moved";
@@ -162,7 +162,7 @@ protected:
break;
}
if (state) {
- this->inval(NULL);
+ this->inval(nullptr);
lua_State* L = fLua->get();
lua_getglobal(L, gClickName);
fLua->pushScalar(click->fCurr.x());