//
// GJAccountSettingsLayer::closeAccInputNodes from 0x14039ec50 to 0x14039edb5 (357 bytes)
//
// 5 xrefs:
// > GJAccountSettingsLayer::onClose @ 0x14039edd0
// > GJAccountSettingsLayer::onUpdate @ 0x14039ee2e
// > GJAccountSettingsLayer::keyBackClicked @ 0x14039f307
// > UpdateAccountSettingsPopup::onClose @ 0x1403a0c9d
// > ??> @ 0x1409234c8
//
// 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:31:16 +0000
//
// Hidden C++ exception states: #wind=1
void __fastcall GJAccountSettingsLayer::closeAccInputNodes(__int64 a1, __int64 a2)
{
unsigned int *v3; // rbx
__int64 v4; // rax
_QWORD **v5; // rbx
_QWORD **i; // rsi
_QWORD *v7; // rdi
_BYTE *v8; // rax
size_t v9; // r8
__int64 v10; // rax
void *v11; // rcx
int v12; // [rsp+30h] [rbp-48h] BYREF
__int128 v13; // [rsp+38h] [rbp-40h] BYREF
__int128 v14; // [rsp+48h] [rbp-30h]
if ( a2 )
{
v3 = *(unsigned int **)(a2 + 56);
v4 = *v3;
if ( (_DWORD)v4 )
{
v5 = *((_QWORD ***)v3 + 2);
for ( i = &v5[v4 - 1]; v5 <= i; ++v5 )
{
v7 = *v5;
if ( !*v5 )
break;
v7[75] = 0;
(*(void (__fastcall **)(_QWORD *, _QWORD))(*v7 + 1032LL))(v7, 0);
v12 = (*(__int64 (__fastcall **)(_QWORD *))(*v7 + 56LL))(v7);
v8 = (_BYTE *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)(v7[74] + 600LL) + 8LL))(v7[74] + 600LL);
v13 = 0;
v14 = 0;
v9 = -1;
do
++v9;
while ( v8[v9] );
sub_14003D230(&v13, v8, v9);
v10 = sub_1402D6130((__int64 *)(a1 + 696), &v12);
sub_140059C40(v10, (__int64)&v13);
if ( *((_QWORD *)&v14 + 1) > 0xFu )
{
v11 = (void *)v13;
if ( (unsigned __int64)(*((_QWORD *)&v14 + 1) + 1LL) >= 0x1000 )
{
v11 = *(void **)(v13 - 8);
if ( (unsigned __int64)(v13 - (_QWORD)v11 - 8) > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
}
j_j_free(v11);
}
}
}
}
}