Exemplo n.º 1
0
NS_TIMELINE_BEGIN

// ActionTimelineData
ActionTimelineData* ActionTimelineData::create(int actionTag)
{
    ActionTimelineData * ret = new (std::nothrow) ActionTimelineData();
    if (ret && ret->init(actionTag))
    {
        ret->autorelease();
        return ret;
    }
    
    delete ret;
    return nullptr;
}
NS_TIMELINE_BEGIN

// ActionTimelineData
ActionTimelineData* ActionTimelineData::create(int actionTag)
{
    ActionTimelineData * ret = new (std::nothrow) ActionTimelineData();
    if (ret && ret->init(actionTag))
    {
        ret->autorelease();
    }
    else
    {
        CC_SAFE_DELETE(ret);
    }
    return ret;
}