//
// PlatformerControlsPopup::refreshUploadColumn from 0xcfa724 to 0xcfa878 (340 bytes)
//
// 2 xrefs:
// > PlatformerControlsPopup::refreshClassUI @ 0xcfa918
// > ??> @ 0x75df0
//
// 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 13:06:50 +0000
//
__int64 __fastcall PlatformerControlsPopup::refreshUploadColumn(__int64 this, int a2)
{
__int64 v2; // x19
CCMenuItemToggler **v4; // x23
_QWORD *v5; // x21
_BOOL4 IsCustom; // w26
__int64 v7; // x20
int v8; // w22
CCMenuItemToggler *v9; // x27
CCMenuItemToggler *v10; // x27
v2 = this;
if ( *(_BYTE *)(this + 1200) && *(_QWORD *)(this + 1048) )
{
v4 = (CCMenuItemToggler **)(this + 1224);
v5 = (_QWORD *)(this + 1248);
IsCustom = PlatformerControlsPopup::sourceIsCustom((PlatformerControlsPopup *)this);
v7 = 0;
do
{
v8 = *(_DWORD *)((char *)&unk_11A54E0 + v7);
if ( (v8 & a2) != 0 )
{
v10 = *v4;
(*(void (__fastcall **)(CCMenuItemToggler *, _BOOL4))(*(_QWORD *)*v4 + 1056LL))(*v4, IsCustom);
CCMenuItemToggler::toggle(v10, (v8 & *(_DWORD *)(*(_QWORD *)(v2 + 1048) + 1848LL)) != 0);
(*(void (__fastcall **)(_QWORD, __int64))(*(_QWORD *)*v5 + 912LL))(*v5, 0xFFFFFFFFLL);
}
else
{
*(_DWORD *)(*(_QWORD *)(v2 + 1048) + 1848LL) &= ~v8;
v9 = *v4;
(*(void (__fastcall **)(CCMenuItemToggler *, _QWORD))(*(_QWORD *)*v4 + 1056LL))(*v4, 0);
CCMenuItemToggler::toggle(v9, (v8 & *(_DWORD *)(*(_QWORD *)(v2 + 1048) + 1848LL)) != 0);
(*(void (__fastcall **)(_QWORD, __int64))(*(_QWORD *)*v5 + 912LL))(*v5, 100);
}
v7 += 4;
this = (*(__int64 (**)(void))(*(_QWORD *)v5[1] + 912LL))();
++v4;
v5 += 2;
}
while ( v7 != 12 );
}
return this;
}