mirror of https://github.com/axmolengine/axmol.git
getLastValidIterator() may return a invalid iterator m_array.end().
don't know where this code came from.
This commit is contained in:
parent
255293119d
commit
dccf577ad3
|
@ -264,7 +264,7 @@ CCTouchHandler* CCTouchDispatcher::findHandler(CCTouchDelegate *pDelegate)
|
||||||
|
|
||||||
void CCTouchDispatcher::rearrangeHandlers(CCMutableArray<CCTouchHandler*> *pArray)
|
void CCTouchDispatcher::rearrangeHandlers(CCMutableArray<CCTouchHandler*> *pArray)
|
||||||
{
|
{
|
||||||
std::sort(pArray->begin(), pArray->getLastValidIterator(), less);
|
std::sort(pArray->begin(), pArray->end(), less);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CCTouchDispatcher::setPriority(int nPriority, CCTouchDelegate *pDelegate)
|
void CCTouchDispatcher::setPriority(int nPriority, CCTouchDelegate *pDelegate)
|
||||||
|
|
Loading…
Reference in New Issue