//
// CustomSongWidget::FLAlert_Clicked from 0x1400cd9d0 to 0x1400cda75 (165 bytes)
//
// 2 xrefs:
// > ??> @ 0x14054ec50
// > ??> @ 0x1406c8430
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
// Hidden C++ exception states: #wind=1
void CustomSongWidget::FLAlert_Clicked(CustomSongWidget *a1, FLAlertLayer *a2, bool a3)
{
int v5; // eax
GameManager *v6; // rcx
void *v7; // [rsp+38h] [rbp+10h]
v5 = ((__int64 (__fastcall *)(FLAlertLayer *))a2->getTag)(a2) - 1;
if ( v5 )
{
if ( v5 == 1 && a3 )
CustomSongWidget::deleteSong((CustomSongWidget *)((char *)a1 - 328));
}
else if ( a3 )
{
v6 = (GameManager *)qword_1406C2ED8;
if ( !qword_1406C2ED8 )
{
v7 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v7);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v6 = (GameManager *)qword_1406C2ED8;
}
GameManager::setGameVariable(v6, "0016", 1);
CustomSongWidget::onDownload((CustomSongWidget *)((char *)a1 - 328), nullptr);
}
}