//
// cocos2d::CCIMEDelegate::~CCIMEDelegate from 0x1800b83b0 to 0x1800b8441 (145 bytes)
//
// 6 xrefs:
// > sub_1800B84D0 @ 0x1800b852e
// > cocos2d::CCTextFieldTTF::~CCTextFieldTTF @ 0x1800b8d33
// > sub_1800E8D70 @ 0x1800e8d7e
// > sub_1800B84D0 @ 0x1800b84ec
// > ??> @ 0x18014cf68
// > ??> @ 0x1801c2bd4
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:22:22 +0000
//
void __fastcall cocos2d::CCIMEDelegate::~CCIMEDelegate(cocos2d::CCIMEDelegate *this)
{
struct cocos2d::CCIMEDispatcher *v2; // r9
void ****v3; // r8
void **v4; // rdx
void **v5; // rcx
void ***v6; // rax
void ****v7; // r8
*(_QWORD *)this = &cocos2d::CCIMEDelegate::`vftable';
v2 = cocos2d::CCIMEDispatcher::sharedDispatcher();
v3 = *(void *****)v2;
if ( *(_QWORD *)v2 )
{
v4 = (void **)*v3;
v5 = **v3;
if ( v5 != (void **)*v3 )
{
while ( this != v5[2] )
{
v5 = (void **)*v5;
if ( v5 == v4 )
return;
}
if ( v4 != v5 )
{
v6 = v3[2];
if ( v6 )
{
if ( v5[2] == v6 )
v3[2] = nullptr;
}
v7 = *(void *****)v2;
*(_QWORD *)v5[1] = *v5;
*((_QWORD *)*v5 + 1) = v5[1];
v7[1] = (void ***)((char *)v7[1] - 1);
j_j_free_0(v5);
}
}
}
}