CColorView* CColorView::create() { CColorView* pRet = new CColorView(); if( pRet && pRet->init() ) { pRet->autorelease(); return pRet; } CC_SAFE_DELETE(pRet); return pRet; }
CColorView* CColorView::create(const Color4B& color) { CColorView* pRet = new CColorView(); if( pRet && pRet->initWithColor(color) ) { pRet->autorelease(); return pRet; } CC_SAFE_DELETE(pRet); return NULL; }