mirror of https://github.com/axmolengine/axmol.git
issue #1425: change the design of CCCallFunc::create(int nHandler)
This commit is contained in:
parent
96e621bae8
commit
b815504d69
|
@ -384,11 +384,11 @@ CCCallFunc * CCCallFunc::create(int nHandler)
|
|||
if (pRet) {
|
||||
pRet->m_nScriptHandler = nHandler;
|
||||
pRet->autorelease();
|
||||
return pRet;
|
||||
}
|
||||
|
||||
CC_SAFE_DELETE(pRet);
|
||||
return NULL;
|
||||
else{
|
||||
CC_SAFE_DELETE(pRet);
|
||||
}
|
||||
return pRet;
|
||||
}
|
||||
|
||||
bool CCCallFunc::initWithTarget(CCObject* pSelectorTarget) {
|
||||
|
@ -477,11 +477,11 @@ CCCallFuncN * CCCallFuncN::create(int nHandler)
|
|||
if (pRet) {
|
||||
pRet->m_nScriptHandler = nHandler;
|
||||
pRet->autorelease();
|
||||
return pRet;
|
||||
}
|
||||
|
||||
CC_SAFE_DELETE(pRet);
|
||||
return NULL;
|
||||
else{
|
||||
CC_SAFE_DELETE(pRet);
|
||||
}
|
||||
return pRet;
|
||||
}
|
||||
|
||||
bool CCCallFuncN::initWithTarget(CCObject* pSelectorTarget,
|
||||
|
|
Loading…
Reference in New Issue