mirror of https://github.com/axmolengine/axmol.git
Merge branch 'gles20' of https://github.com/cocos2d/cocos2d-x into test-js-device-crash
This commit is contained in:
commit
0abcd694c6
38
CHANGELOG
38
CHANGELOG
|
@ -1,3 +1,41 @@
|
|||
cocos2d-2.0-x-2.0.4 @Nov.2 2012
|
||||
[all platforms]
|
||||
Bug #1473: fix a bug that CCScale9Sprite does not support rotated spriteframe in atlas
|
||||
Bug #1494: fix a bug that missing removing auto-release object from AutoReleasePool if it invokes 'autorelease' method more than one time
|
||||
Bug #1495: fix a bug that CCScrollView display area and touch area are wrong if its parent's postion isn't at CCPointZero in world
|
||||
Bug #1508: fix a bug that potential observer array modification while it's traversed in CCNotificationCenter
|
||||
Bug #1510: fix a bug that application will freeze when 'numberOfCellsInTableView' returns zero
|
||||
Bug #1516: fix a bug that the font size of labels for displaying FPS,SPF,DrawCount is incorrect in different design resolutions
|
||||
Bug #1536: CCControl* should not respond to touches if the control is not visible
|
||||
Bug #1538: fix a logic error in CCControlHuePicker::checkSliderPosition()
|
||||
Bug #1543: fix a bug that CCLayerGradient background of CocosBuilderTest can't be shown
|
||||
Feature #1515: add a zoom function for debugging large resolution (e.g.new ipad) app on desktop
|
||||
Refactor #1312: upgrade libcurl to 7.26.0
|
||||
Refactor #1486: apply multi-resolution mechanic on iOS, especially for iphone5
|
||||
Refactor #1520: add comments to describe the usage of multiresolution in HelloCpp
|
||||
Refactor #1521: use relative coordinates in TestCpp
|
||||
Document #1532: write a document describes how to debug games for ipad3 on low-resolution PC
|
||||
Document #1493: add doxygen comments in CCNotificationCenter.h
|
||||
[android]
|
||||
Bug #1466: reload shader for test case "ShaderTest" after it comes from background
|
||||
Bug #1500: fix a bug that CCRenderTexture cannot render properly on some Qualcomm Adreno GPUs
|
||||
Bug #1507: fix a bug that can not play effect for the first time without pre-load effect
|
||||
[iOS]
|
||||
Bug #1527: fix a bug that MoonWarriors can not run on iOS simulator sometimes
|
||||
Refactor #1491: remove dependency of FontLabel lib
|
||||
[javascript binding]
|
||||
Feature #1469: add MoonWarriors as a sample game
|
||||
Refactor #1487: use shared javascript test cases with cocos2d-html5 and cocos2d-iphone
|
||||
Refactor #1517: upgrade SpiderMonkey to FF 16.0.1
|
||||
[lua binding]
|
||||
Bug #1506: fix a compilation error of TestLua if the path of cocos2d-x contains spaces
|
||||
[win32]
|
||||
Bug #1496: fix an error of comparing font's face name in CCImage of win32 port
|
||||
Bug #1511: fix openGL framebuffer access violation
|
||||
Bug #1540: fix win32 CCLuaLog memory leaks and invalid console UTF8 output
|
||||
Feature #1513: add Multi-Touch support for win7/8 tablet or ultrabook
|
||||
Refactor #1512: change writable directory to "C:\Documents and Settings\username\Local Settings\Application Data\your app name" if the app be built in release mode
|
||||
|
||||
cocos2d-2.0-x-2.0.3 @Sep.26 2012
|
||||
[all platforms]
|
||||
Bug #1452: change CCRGBAProtocol to public in order for actions like CCTintTo to have an affect on the CCScale9Sprite
|
||||
|
|
|
@ -234,6 +234,32 @@ CCTransitionRotoZoom::CCTransitionRotoZoom()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionRotoZoom* CCTransitionRotoZoom::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionRotoZoom* pScene = new CCTransitionRotoZoom();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionRotoZoom* CCTransitionRotoZoom::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionRotoZoom* pScene = new CCTransitionRotoZoom();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCTransitionRotoZoom::~CCTransitionRotoZoom()
|
||||
{
|
||||
}
|
||||
|
@ -282,6 +308,32 @@ CCTransitionJumpZoom::~CCTransitionJumpZoom()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionJumpZoom* CCTransitionJumpZoom::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionJumpZoom* pScene = new CCTransitionJumpZoom();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionJumpZoom* CCTransitionJumpZoom::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionJumpZoom* pScene = new CCTransitionJumpZoom();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionJumpZoom::onEnter()
|
||||
{
|
||||
CCTransitionScene::onEnter();
|
||||
|
@ -325,6 +377,32 @@ CCTransitionMoveInL::~CCTransitionMoveInL()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionMoveInL* CCTransitionMoveInL::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInL* pScene = new CCTransitionMoveInL();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionMoveInL* CCTransitionMoveInL::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInL* pScene = new CCTransitionMoveInL();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionMoveInL::onEnter()
|
||||
{
|
||||
CCTransitionScene::onEnter();
|
||||
|
@ -370,6 +448,32 @@ CCTransitionMoveInR::~CCTransitionMoveInR()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionMoveInR* CCTransitionMoveInR::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInR* pScene = new CCTransitionMoveInR();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionMoveInR* CCTransitionMoveInR::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInR* pScene = new CCTransitionMoveInR();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionMoveInR::initScenes()
|
||||
{
|
||||
CCSize s = CCDirector::sharedDirector()->getWinSize();
|
||||
|
@ -386,6 +490,32 @@ CCTransitionMoveInT::~CCTransitionMoveInT()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionMoveInT* CCTransitionMoveInT::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInT* pScene = new CCTransitionMoveInT();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionMoveInT* CCTransitionMoveInT::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInT* pScene = new CCTransitionMoveInT();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionMoveInT::initScenes()
|
||||
{
|
||||
CCSize s = CCDirector::sharedDirector()->getWinSize();
|
||||
|
@ -402,6 +532,32 @@ CCTransitionMoveInB::~CCTransitionMoveInB()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionMoveInB* CCTransitionMoveInB::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInB* pScene = new CCTransitionMoveInB();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionMoveInB* CCTransitionMoveInB::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionMoveInB* pScene = new CCTransitionMoveInB();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionMoveInB::initScenes()
|
||||
{
|
||||
CCSize s = CCDirector::sharedDirector()->getWinSize();
|
||||
|
@ -425,6 +581,32 @@ CCTransitionSlideInL::~CCTransitionSlideInL()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSlideInL* CCTransitionSlideInL::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInL* pScene = new CCTransitionSlideInL();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSlideInL* CCTransitionSlideInL::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInL* pScene = new CCTransitionSlideInL();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionSlideInL::onEnter()
|
||||
{
|
||||
CCTransitionScene::onEnter();
|
||||
|
@ -478,6 +660,32 @@ CCTransitionSlideInR::~CCTransitionSlideInR()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSlideInR* CCTransitionSlideInR::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInR* pScene = new CCTransitionSlideInR();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSlideInR* CCTransitionSlideInR::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInR* pScene = new CCTransitionSlideInR();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionSlideInR::sceneOrder()
|
||||
{
|
||||
m_bIsInSceneOnTop = true;
|
||||
|
@ -507,6 +715,32 @@ CCTransitionSlideInT::~CCTransitionSlideInT()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSlideInT* CCTransitionSlideInT::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInT* pScene = new CCTransitionSlideInT();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSlideInT* CCTransitionSlideInT::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInT* pScene = new CCTransitionSlideInT();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionSlideInT::sceneOrder()
|
||||
{
|
||||
m_bIsInSceneOnTop = false;
|
||||
|
@ -535,6 +769,32 @@ CCTransitionSlideInB::~CCTransitionSlideInB()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSlideInB* CCTransitionSlideInB::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInB* pScene = new CCTransitionSlideInB();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSlideInB* CCTransitionSlideInB::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSlideInB* pScene = new CCTransitionSlideInB();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionSlideInB::sceneOrder()
|
||||
{
|
||||
m_bIsInSceneOnTop = true;
|
||||
|
@ -563,6 +823,32 @@ CCTransitionShrinkGrow::~CCTransitionShrinkGrow()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionShrinkGrow* CCTransitionShrinkGrow::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionShrinkGrow* pScene = new CCTransitionShrinkGrow();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionShrinkGrow* CCTransitionShrinkGrow::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionShrinkGrow* pScene = new CCTransitionShrinkGrow();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionShrinkGrow::onEnter()
|
||||
{
|
||||
CCTransitionScene::onEnter();
|
||||
|
@ -663,6 +949,11 @@ CCTransitionFlipX* CCTransitionFlipX::create(float t, CCScene* s, tOrientation o
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionFlipX* CCTransitionFlipX::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionFlipX::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
|
||||
//
|
||||
// FlipY Transition
|
||||
//
|
||||
|
@ -733,6 +1024,11 @@ CCTransitionFlipY* CCTransitionFlipY::create(float t, CCScene* s, tOrientation o
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionFlipY* CCTransitionFlipY::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionFlipY::create(t, s, kOrientationUpOver);
|
||||
}
|
||||
|
||||
//
|
||||
// FlipAngular Transition
|
||||
//
|
||||
|
@ -803,6 +1099,11 @@ CCTransitionFlipAngular* CCTransitionFlipAngular::create(float t, CCScene* s, tO
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionFlipAngular* CCTransitionFlipAngular::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionFlipAngular::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
|
||||
//
|
||||
// ZoomFlipX Transition
|
||||
//
|
||||
|
@ -881,6 +1182,11 @@ CCTransitionZoomFlipX* CCTransitionZoomFlipX::create(float t, CCScene* s, tOrien
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionZoomFlipX* CCTransitionZoomFlipX::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionZoomFlipX::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
|
||||
//
|
||||
// ZoomFlipY Transition
|
||||
//
|
||||
|
@ -960,6 +1266,11 @@ CCTransitionZoomFlipY* CCTransitionZoomFlipY::create(float t, CCScene* s, tOrien
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionZoomFlipY* CCTransitionZoomFlipY::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionZoomFlipY::create(t, s, kOrientationUpOver);
|
||||
}
|
||||
|
||||
//
|
||||
// ZoomFlipAngular Transition
|
||||
//
|
||||
|
@ -1041,6 +1352,11 @@ CCTransitionZoomFlipAngular* CCTransitionZoomFlipAngular::create(float t, CCScen
|
|||
return pScene;
|
||||
}
|
||||
|
||||
CCTransitionZoomFlipAngular* CCTransitionZoomFlipAngular::create(float t, CCScene* s)
|
||||
{
|
||||
return CCTransitionZoomFlipAngular::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
|
||||
//
|
||||
// Fade Transition
|
||||
//
|
||||
|
@ -1064,6 +1380,11 @@ CCTransitionFade * CCTransitionFade::create(float duration, CCScene *scene, cons
|
|||
return pTransition;
|
||||
}
|
||||
|
||||
CCTransitionFade* CCTransitionFade::create(float duration,CCScene* scene)
|
||||
{
|
||||
return CCTransitionFade::create(duration, scene, ccBLACK);
|
||||
}
|
||||
|
||||
bool CCTransitionFade::initWithDuration(float duration, CCScene *scene, const ccColor3B& color)
|
||||
{
|
||||
if (CCTransitionScene::initWithDuration(duration, scene))
|
||||
|
@ -1119,6 +1440,31 @@ CCTransitionCrossFade::~CCTransitionCrossFade()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionCrossFade* CCTransitionCrossFade::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionCrossFade* pScene = new CCTransitionCrossFade();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionCrossFade* CCTransitionCrossFade::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionCrossFade* pScene = new CCTransitionCrossFade();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionCrossFade:: draw()
|
||||
{
|
||||
|
@ -1216,6 +1562,31 @@ CCTransitionTurnOffTiles::~CCTransitionTurnOffTiles()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionTurnOffTiles* CCTransitionTurnOffTiles::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionTurnOffTiles* pScene = new CCTransitionTurnOffTiles();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionTurnOffTiles* CCTransitionTurnOffTiles::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionTurnOffTiles* pScene = new CCTransitionTurnOffTiles();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// override addScenes, and change the order
|
||||
void CCTransitionTurnOffTiles::sceneOrder()
|
||||
|
@ -1261,6 +1632,31 @@ CCTransitionSplitCols::~CCTransitionSplitCols()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSplitCols* CCTransitionSplitCols::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSplitCols* pScene = new CCTransitionSplitCols();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSplitCols* CCTransitionSplitCols::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSplitCols* pScene = new CCTransitionSplitCols();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionSplitCols::onEnter()
|
||||
{
|
||||
|
@ -1311,6 +1707,31 @@ CCTransitionSplitRows::~CCTransitionSplitRows()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionSplitRows* CCTransitionSplitRows::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSplitRows* pScene = new CCTransitionSplitRows();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionSplitRows* CCTransitionSplitRows::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionSplitRows* pScene = new CCTransitionSplitRows();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCActionInterval* CCTransitionSplitRows::action()
|
||||
{
|
||||
|
@ -1327,6 +1748,31 @@ CCTransitionFadeTR::~CCTransitionFadeTR()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionFadeTR* CCTransitionFadeTR::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeTR* pScene = new CCTransitionFadeTR();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionFadeTR* CCTransitionFadeTR::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeTR* pScene = new CCTransitionFadeTR();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionFadeTR::sceneOrder()
|
||||
{
|
||||
|
@ -1379,6 +1825,32 @@ CCTransitionFadeBL::~CCTransitionFadeBL()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionFadeBL* CCTransitionFadeBL::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeBL* pScene = new CCTransitionFadeBL();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionFadeBL* CCTransitionFadeBL::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeBL* pScene = new CCTransitionFadeBL();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCActionInterval* CCTransitionFadeBL::actionWithSize(const ccGridSize& size)
|
||||
{
|
||||
return CCFadeOutBLTiles::create(size, m_fDuration);
|
||||
|
@ -1394,6 +1866,32 @@ CCTransitionFadeUp::~CCTransitionFadeUp()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionFadeUp* CCTransitionFadeUp::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeUp* pScene = new CCTransitionFadeUp();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionFadeUp* CCTransitionFadeUp::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeUp* pScene = new CCTransitionFadeUp();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCActionInterval* CCTransitionFadeUp::actionWithSize(const ccGridSize& size)
|
||||
{
|
||||
return CCFadeOutUpTiles::create(size, m_fDuration);
|
||||
|
@ -1409,6 +1907,32 @@ CCTransitionFadeDown::~CCTransitionFadeDown()
|
|||
{
|
||||
}
|
||||
|
||||
CCTransitionFadeDown* CCTransitionFadeDown::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeDown* pScene = new CCTransitionFadeDown();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionFadeDown* CCTransitionFadeDown::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionFadeDown* pScene = new CCTransitionFadeDown();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCActionInterval* CCTransitionFadeDown::actionWithSize(const ccGridSize& size)
|
||||
{
|
||||
return CCFadeOutDownTiles::create(size, m_fDuration);
|
||||
|
|
|
@ -41,32 +41,6 @@ NS_CC_BEGIN
|
|||
//c/c++ don't support object creation of using class name
|
||||
//so, all classes need creation method.
|
||||
|
||||
#define OLD_TRANSITION_CREATE_FUNC(_Type) \
|
||||
CC_DEPRECATED_ATTRIBUTE static _Type* transitionWithDuration(float t, CCScene* scene) \
|
||||
{ \
|
||||
_Type* pScene = new _Type(); \
|
||||
if(pScene && pScene->initWithDuration(t, scene)) \
|
||||
{ \
|
||||
pScene->autorelease(); \
|
||||
return pScene; \
|
||||
} \
|
||||
CC_SAFE_DELETE(pScene); \
|
||||
return NULL; \
|
||||
}
|
||||
|
||||
#define TRANSITION_CREATE_FUNC(_Type) \
|
||||
static _Type* create(float t, CCScene* scene) \
|
||||
{ \
|
||||
_Type* pScene = new _Type(); \
|
||||
if(pScene && pScene->initWithDuration(t, scene)) \
|
||||
{ \
|
||||
pScene->autorelease(); \
|
||||
return pScene; \
|
||||
} \
|
||||
CC_SAFE_DELETE(pScene); \
|
||||
return NULL; \
|
||||
}
|
||||
|
||||
class CCActionInterval;
|
||||
class CCNode;
|
||||
|
||||
|
@ -174,8 +148,8 @@ public:
|
|||
virtual ~CCTransitionRotoZoom();
|
||||
virtual void onEnter();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionRotoZoom);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionRotoZoom);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionRotoZoom* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionRotoZoom* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionJumpZoom:
|
||||
|
@ -188,8 +162,8 @@ public:
|
|||
virtual ~CCTransitionJumpZoom();
|
||||
virtual void onEnter();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionJumpZoom);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionJumpZoom);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionJumpZoom* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionJumpZoom* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionMoveInL:
|
||||
|
@ -209,8 +183,8 @@ public:
|
|||
|
||||
virtual void onEnter();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionMoveInL);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionMoveInL);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionMoveInL* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionMoveInL* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionMoveInR:
|
||||
|
@ -223,8 +197,8 @@ public:
|
|||
virtual ~CCTransitionMoveInR();
|
||||
virtual void initScenes();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionMoveInR);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionMoveInR);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionMoveInR* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionMoveInR* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionMoveInT:
|
||||
|
@ -237,8 +211,8 @@ public:
|
|||
virtual ~CCTransitionMoveInT();
|
||||
virtual void initScenes();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionMoveInT);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionMoveInT);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionMoveInT* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionMoveInT* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionMoveInB:
|
||||
|
@ -251,8 +225,8 @@ public:
|
|||
virtual ~CCTransitionMoveInB();
|
||||
virtual void initScenes();
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionMoveInB);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionMoveInB);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionMoveInB* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionMoveInB* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionSlideInL:
|
||||
|
@ -273,8 +247,8 @@ public:
|
|||
|
||||
virtual CCActionInterval* easeActionWithAction(CCActionInterval * action);
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSlideInL);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSlideInL);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSlideInL* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSlideInL* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
};
|
||||
|
@ -293,8 +267,8 @@ public:
|
|||
/** returns the action that will be performed by the incoming and outgoing scene */
|
||||
virtual CCActionInterval* action(void);
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSlideInR);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSlideInR);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSlideInR* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSlideInR* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
};
|
||||
|
@ -313,8 +287,8 @@ public:
|
|||
/** returns the action that will be performed by the incoming and outgoing scene */
|
||||
virtual CCActionInterval* action(void);
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSlideInB);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSlideInB);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSlideInB* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSlideInB* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
};
|
||||
|
@ -333,8 +307,8 @@ public:
|
|||
/** returns the action that will be performed by the incoming and outgoing scene */
|
||||
virtual CCActionInterval* action(void);
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSlideInT);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSlideInT);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSlideInT* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSlideInT* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
};
|
||||
|
@ -351,8 +325,8 @@ public:
|
|||
virtual void onEnter();
|
||||
virtual CCActionInterval* easeActionWithAction(CCActionInterval * action);
|
||||
|
||||
TRANSITION_CREATE_FUNC(CCTransitionShrinkGrow);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionShrinkGrow);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionShrinkGrow* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionShrinkGrow* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFlipX:
|
||||
|
@ -370,9 +344,7 @@ public:
|
|||
// @deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFlipX* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationRightOver);
|
||||
static CCTransitionFlipX* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionFlipX* create(float t, CCScene* s) {
|
||||
return CCTransitionFlipX::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
static CCTransitionFlipX* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFlipY:
|
||||
|
@ -390,9 +362,7 @@ public:
|
|||
//@deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFlipY* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationUpOver);
|
||||
static CCTransitionFlipY* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionFlipY* create(float t, CCScene* s) {
|
||||
return CCTransitionFlipY::create(t, s, kOrientationUpOver);
|
||||
}
|
||||
static CCTransitionFlipY* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFlipAngular:
|
||||
|
@ -410,9 +380,7 @@ public:
|
|||
//@deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFlipAngular* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationRightOver);
|
||||
static CCTransitionFlipAngular* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionFlipAngular* create(float t, CCScene* s) {
|
||||
return CCTransitionFlipAngular::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
static CCTransitionFlipAngular* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionZoomFlipX:
|
||||
|
@ -430,9 +398,7 @@ public:
|
|||
//@deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionZoomFlipX* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationRightOver);
|
||||
static CCTransitionZoomFlipX* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionZoomFlipX* create(float t, CCScene* s) {
|
||||
return CCTransitionZoomFlipX::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
static CCTransitionZoomFlipX* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionZoomFlipY:
|
||||
|
@ -450,9 +416,7 @@ public:
|
|||
//@deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionZoomFlipY* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationUpOver);
|
||||
static CCTransitionZoomFlipY* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionZoomFlipY* create(float t, CCScene* s) {
|
||||
return CCTransitionZoomFlipY::create(t, s, kOrientationUpOver);
|
||||
}
|
||||
static CCTransitionZoomFlipY* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionZoomFlipAngular:
|
||||
|
@ -470,9 +434,7 @@ public:
|
|||
//@deprecated: This interface will be deprecated sooner or later.
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionZoomFlipAngular* transitionWithDuration(float t, CCScene* s, tOrientation o = kOrientationRightOver);
|
||||
static CCTransitionZoomFlipAngular* create(float t, CCScene* s, tOrientation o);
|
||||
static CCTransitionZoomFlipAngular* create(float t, CCScene* s) {
|
||||
return CCTransitionZoomFlipAngular::create(t, s, kOrientationRightOver);
|
||||
}
|
||||
static CCTransitionZoomFlipAngular* create(float t, CCScene* s);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFade:
|
||||
|
@ -498,9 +460,7 @@ public:
|
|||
* Example: FadeTransition::create(2, scene, ccc3(255,0,0); // red color
|
||||
*/
|
||||
static CCTransitionFade* create(float duration,CCScene* scene, const ccColor3B& color);
|
||||
static CCTransitionFade* create(float duration,CCScene* scene) {
|
||||
return CCTransitionFade::create(duration, scene, ccBLACK);
|
||||
}
|
||||
static CCTransitionFade* create(float duration,CCScene* scene);
|
||||
|
||||
/** initializes the transition with a duration and with an RGB color */
|
||||
virtual bool initWithDuration(float t, CCScene*scene ,const ccColor3B& color);
|
||||
|
@ -526,8 +486,8 @@ public :
|
|||
virtual void onExit();
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionCrossFade);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionCrossFade);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionCrossFade* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionCrossFade* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionTurnOffTiles:
|
||||
|
@ -543,8 +503,8 @@ public :
|
|||
virtual CCActionInterval * easeActionWithAction(CCActionInterval * action);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionTurnOffTiles);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionTurnOffTiles);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionTurnOffTiles* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionTurnOffTiles* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
};
|
||||
|
@ -563,8 +523,8 @@ public:
|
|||
virtual CCActionInterval * easeActionWithAction(CCActionInterval * action);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSplitCols);
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSplitCols);
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSplitCols* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSplitCols* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionSplitRows:
|
||||
|
@ -579,8 +539,8 @@ public:
|
|||
virtual CCActionInterval* action(void);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionSplitRows)
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionSplitRows)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionSplitRows* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionSplitRows* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFadeTR:
|
||||
|
@ -596,11 +556,10 @@ public:
|
|||
virtual CCActionInterval* easeActionWithAction(CCActionInterval * action);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionFadeTR)
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionFadeTR)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFadeTR* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionFadeTR* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual void sceneOrder();
|
||||
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFadeBL:
|
||||
|
@ -614,8 +573,8 @@ public:
|
|||
virtual CCActionInterval* actionWithSize(const ccGridSize& size);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionFadeBL)
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionFadeBL)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFadeBL* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionFadeBL* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFadeUp:
|
||||
|
@ -629,8 +588,8 @@ public:
|
|||
virtual CCActionInterval* actionWithSize(const ccGridSize& size);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionFadeUp)
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionFadeUp)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFadeUp* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionFadeUp* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
/** @brief CCTransitionFadeDown:
|
||||
|
@ -644,8 +603,8 @@ public:
|
|||
virtual CCActionInterval* actionWithSize(const ccGridSize& size);
|
||||
|
||||
public:
|
||||
TRANSITION_CREATE_FUNC(CCTransitionFadeDown)
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionFadeDown)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionFadeDown* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionFadeDown* create(float t, CCScene* scene);
|
||||
};
|
||||
|
||||
// end of transition group
|
||||
|
|
|
@ -48,6 +48,32 @@ CCTransitionProgress::CCTransitionProgress()
|
|||
|
||||
}
|
||||
|
||||
CCTransitionProgress* CCTransitionProgress::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgress* pScene = new CCTransitionProgress();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgress* CCTransitionProgress::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgress* pScene = new CCTransitionProgress();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// CCTransitionProgress
|
||||
void CCTransitionProgress::onEnter()
|
||||
{
|
||||
|
@ -140,7 +166,58 @@ CCProgressTimer* CCTransitionProgressRadialCCW::progressTimerNodeWithRenderTextu
|
|||
return pNode;
|
||||
}
|
||||
|
||||
CCTransitionProgressRadialCCW* CCTransitionProgressRadialCCW::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressRadialCCW* pScene = new CCTransitionProgressRadialCCW();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressRadialCCW* CCTransitionProgressRadialCCW::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressRadialCCW* pScene = new CCTransitionProgressRadialCCW();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// CCTransitionProgressRadialCW
|
||||
CCTransitionProgressRadialCW* CCTransitionProgressRadialCW::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressRadialCW* pScene = new CCTransitionProgressRadialCW();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressRadialCW* CCTransitionProgressRadialCW::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressRadialCW* pScene = new CCTransitionProgressRadialCW();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCProgressTimer* CCTransitionProgressRadialCW::progressTimerNodeWithRenderTexture(CCRenderTexture* texture)
|
||||
{
|
||||
|
@ -162,6 +239,31 @@ CCProgressTimer* CCTransitionProgressRadialCW::progressTimerNodeWithRenderTextur
|
|||
}
|
||||
|
||||
// CCTransitionProgressHorizontal
|
||||
CCTransitionProgressHorizontal* CCTransitionProgressHorizontal::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressHorizontal* pScene = new CCTransitionProgressHorizontal();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressHorizontal* CCTransitionProgressHorizontal::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressHorizontal* pScene = new CCTransitionProgressHorizontal();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCProgressTimer* CCTransitionProgressHorizontal::progressTimerNodeWithRenderTexture(CCRenderTexture* texture)
|
||||
{
|
||||
|
@ -184,6 +286,31 @@ CCProgressTimer* CCTransitionProgressHorizontal::progressTimerNodeWithRenderText
|
|||
}
|
||||
|
||||
// CCTransitionProgressVertical
|
||||
CCTransitionProgressVertical* CCTransitionProgressVertical::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressVertical* pScene = new CCTransitionProgressVertical();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressVertical* CCTransitionProgressVertical::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressVertical* pScene = new CCTransitionProgressVertical();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCProgressTimer* CCTransitionProgressVertical::progressTimerNodeWithRenderTexture(CCRenderTexture* texture)
|
||||
{
|
||||
|
@ -207,6 +334,31 @@ CCProgressTimer* CCTransitionProgressVertical::progressTimerNodeWithRenderTextur
|
|||
|
||||
|
||||
// CCTransitionProgressInOut
|
||||
CCTransitionProgressInOut* CCTransitionProgressInOut::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressInOut* pScene = new CCTransitionProgressInOut();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressInOut* CCTransitionProgressInOut::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressInOut* pScene = new CCTransitionProgressInOut();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CCTransitionProgressInOut::sceneOrder()
|
||||
{
|
||||
|
@ -242,6 +394,31 @@ CCProgressTimer* CCTransitionProgressInOut::progressTimerNodeWithRenderTexture(C
|
|||
|
||||
|
||||
// CCTransitionProgressOutIn
|
||||
CCTransitionProgressOutIn* CCTransitionProgressOutIn::create(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressOutIn* pScene = new CCTransitionProgressOutIn();
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
CCTransitionProgressOutIn* CCTransitionProgressOutIn::transitionWithDuration(float t, CCScene* scene)
|
||||
{
|
||||
CCTransitionProgressOutIn* pScene = new CCTransitionProgressOutIn();
|
||||
|
||||
if(pScene && pScene->initWithDuration(t, scene))
|
||||
{
|
||||
pScene->autorelease();
|
||||
return pScene;
|
||||
}
|
||||
CC_SAFE_DELETE(pScene);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
CCProgressTimer* CCTransitionProgressOutIn::progressTimerNodeWithRenderTexture(CCRenderTexture* texture)
|
||||
{
|
||||
|
|
|
@ -42,8 +42,8 @@ class CCRenderTexture;
|
|||
class CC_DLL CCTransitionProgress : public CCTransitionScene
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgress)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgress)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgress* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgress* create(float t, CCScene* scene);
|
||||
|
||||
CCTransitionProgress();
|
||||
virtual void onEnter();
|
||||
|
@ -64,8 +64,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressRadialCCW : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressRadialCCW)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressRadialCCW)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressRadialCCW* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressRadialCCW* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
|
||||
|
@ -78,8 +78,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressRadialCW : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressRadialCW)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressRadialCW)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressRadialCW* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressRadialCW* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
|
||||
|
@ -91,8 +91,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressHorizontal : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressHorizontal)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressHorizontal)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressHorizontal* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressHorizontal* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
|
||||
|
@ -101,8 +101,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressVertical : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressVertical)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressVertical)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressVertical* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressVertical* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
|
||||
|
@ -111,8 +111,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressInOut : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressInOut)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressInOut)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressInOut* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressInOut* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
virtual void sceneOrder();
|
||||
|
@ -122,8 +122,8 @@ protected:
|
|||
class CC_DLL CCTransitionProgressOutIn : public CCTransitionProgress
|
||||
{
|
||||
public:
|
||||
OLD_TRANSITION_CREATE_FUNC(CCTransitionProgressOutIn)
|
||||
TRANSITION_CREATE_FUNC(CCTransitionProgressOutIn)
|
||||
CC_DEPRECATED_ATTRIBUTE static CCTransitionProgressOutIn* transitionWithDuration(float t, CCScene* scene);
|
||||
static CCTransitionProgressOutIn* create(float t, CCScene* scene);
|
||||
protected:
|
||||
virtual CCProgressTimer* progressTimerNodeWithRenderTexture(CCRenderTexture* texture);
|
||||
|
||||
|
|
Loading…
Reference in New Issue