//
// GJScaleControl::finishTouch from 0x1401a3680 to 0x1401a36e3 (99 bytes)
//
// 3 xrefs:
// > GJScaleControl::ccTouchEnded @ 0x1401a44b4
// > EditorUI::deactivateScaleControl @ 0x140202e06
// > ??> @ 0x1409199e8
//
// 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:27:49 +0000
//
__int64 __fastcall GJScaleControl::finishTouch(__int64 a1)
{
__int64 v2; // rcx
__int64 result; // rax
__int64 v4; // rcx
v2 = *(_QWORD *)(a1 + 568);
if ( v2 )
result = (*(__int64 (__fastcall **)(__int64, _QWORD, _QWORD))(*(_QWORD *)(v2 + 320) + 32LL))(v2 + 320, 0, 0);
*(_QWORD *)(a1 + 568) = 0;
if ( *(_DWORD *)(a1 + 432) != -1 )
{
v4 = *(_QWORD *)(a1 + 576);
*(_DWORD *)(a1 + 432) = -1;
if ( v4 )
return (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v4 + 32LL))(v4);
}
return result;
}