//
// cocos2d::CCTouchDispatcher::removeDelegate from 0x10014f0d4 to 0x10014f150 (124 bytes)
//
// 2 xrefs:
// > cocos2d::CCLayer::setTouchEnabled @ 0x100148840
// > cocos2d::CCLayer::onExit @ 0x100148e00
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall cocos2d::CCTouchDispatcher::removeDelegate(
cocos2d::CCTouchDispatcher *a1,
cocos2d::CCTouchDelegate *a2)
{
cocos2d::CCTouchHandler *Handler; // x0
if ( a2 )
{
if ( a1->m_bLocked )
{
Handler = cocos2d::CCTouchDispatcher::findHandler(a1, a1->m_pHandlersToAdd, a2);
if ( Handler )
{
sub_10024A444(a1->m_pHandlersToAdd, Handler, 1);
}
else
{
sub_100353C08(a1->m_pHandlersToRemove, a2);
a1->m_bToRemove = 1;
}
}
else
{
cocos2d::CCTouchDispatcher::forceRemoveDelegate(a1, a2);
}
}
}