//
// cocos2d::CCIMEDispatcher::detachDelegateWithIME from 0x1001d3b3c to 0x1001d3bb0 (116 bytes)
//
// 1 xrefs:
// > cocos2d::CCIMEDelegate::detachWithIME @ 0x1001d3b38
//
// 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
//
bool __fastcall cocos2d::CCIMEDispatcher::detachDelegateWithIME(
cocos2d::CCIMEDispatcher *a1,
cocos2d::CCIMEDelegate *a2)
{
cocos2d::CCIMEDispatcher *v2; // x20
v2 = a1;
LOBYTE(a1) = 0;
if ( a2 && v2->m_pImpl )
{
if ( *((cocos2d::CCIMEDelegate **)v2->m_pImpl + 3) == a2 )
{
LODWORD(a1) = ((__int64 (__fastcall *)(cocos2d::CCIMEDelegate *))a2->canDetachWithIME)(a2);
if ( (_DWORD)a1 )
{
*((_QWORD *)v2->m_pImpl + 3) = 0;
((void (__fastcall *)(cocos2d::CCIMEDelegate *))a2->didDetachWithIME)(a2);
LOBYTE(a1) = 1;
}
}
else
{
LOBYTE(a1) = 0;
}
}
return (char)a1;
}