fix: cleanup scheduler after call CCDirector::end()

This commit is contained in:
YuLei 2012-09-04 01:21:32 +08:00
parent 03374fa83b
commit 39f672e5bf
1 changed files with 3 additions and 0 deletions

View File

@ -591,6 +591,9 @@ void CCDirector::end()
void CCDirector::purgeDirector() void CCDirector::purgeDirector()
{ {
// cleanup scheduler
getScheduler()->unscheduleAllSelectors();
// don't release the event handlers // don't release the event handlers
// They are needed in case the director is run again // They are needed in case the director is run again
m_pTouchDispatcher->removeAllDelegates(); m_pTouchDispatcher->removeAllDelegates();