//
// EditorUI::windowClosed from 0x7c08e4 to 0x7c0a0c (296 bytes)
//
// 2 xrefs:
// > EditorWindowPopup::onClose @ 0xcda2fc
// > ??> @ 0x63160
//
// This function is hookable on this platform (idp: arm, 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 12:54:06 +0000
//
void __fastcall EditorUI::windowClosed(EditorUI *this, EditorWindowPopup *a2)
{
EditorWindowPopup **v2; // x2
unsigned __int64 v4; // x4
EditorWindowPopup *v5; // x6
unsigned __int64 v6; // x8
EditorWindowPopup *v7; // x5
__int64 v8; // x9
EditorWindowPopup *v9; // x7
unsigned __int64 v10; // x5
__int64 v11; // x11
EditorWindowPopup **i; // x1
EditorWindowPopup *v13; // x0
unsigned __int64 v14; // x0
unsigned __int64 v15; // x0
unsigned __int64 v16; // x7
__int64 v17; // x0
v2 = *((EditorWindowPopup ***)this + 74);
if ( v2 )
{
while ( v2[3] != a2 )
{
v2 = (EditorWindowPopup **)*v2;
if ( !v2 )
return;
}
v4 = *((_QWORD *)this + 73);
v5 = *v2;
v6 = v4 - 1;
v7 = v2[1];
v8 = (v4 - 1) & v4;
v9 = *v2;
if ( v8 )
v10 = (unsigned __int64)v7 % v4;
else
v10 = v6 & (unsigned __int64)v7;
v11 = *((_QWORD *)this + 72);
for ( i = *(EditorWindowPopup ***)(v11 + 8 * v10); *i != (EditorWindowPopup *)v2; i = (EditorWindowPopup **)*i )
;
if ( i == (EditorWindowPopup **)((char *)this + 592)
|| ((v13 = i[1], v8) ? (v14 = (unsigned __int64)v13 % v4) : (v14 = v6 & (unsigned __int64)v13), v10 != v14) )
{
if ( v5 )
{
v15 = *((_QWORD *)v5 + 1);
if ( v8 )
{
v16 = v15 / v4;
if ( v10 == v15 % v4 )
{
LABEL_21:
v17 = v15 - v16 * v4;
goto LABEL_22;
}
}
else
{
v17 = v6 & v15;
if ( v10 == v17 )
goto LABEL_22;
}
}
*(_QWORD *)(v11 + 8 * v10) = 0;
v5 = *v2;
v9 = *v2;
}
if ( !v5 )
{
LABEL_24:
*i = v9;
*v2 = nullptr;
--*((_QWORD *)this + 75);
operator delete(v2);
return;
}
v15 = *((_QWORD *)v5 + 1);
if ( v8 )
{
v16 = v15 / v4;
goto LABEL_21;
}
v17 = v6 & v15;
LABEL_22:
v9 = v5;
if ( v10 != v17 )
{
*(_QWORD *)(*((_QWORD *)this + 72) + 8 * v17) = i;
v9 = *v2;
}
goto LABEL_24;
}
}