//
// GJSongBrowser::FLAlert_Clicked from 0x3f741e to 0x3f7480 (98 bytes)
//
// 1 xrefs:
// > `non-virtual thunk to'GJSongBrowser::FLAlert_Clicked @ 0x3f7484
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:47:18 +0000
//
int __fastcall GJSongBrowser::FLAlert_Clicked(GJSongBrowser *this, FLAlertLayer *a2, int a3)
{
int result; // r0
MusicDownloadManager *v6; // r0
unsigned int v7; // r4
cocos2d::CCArray *DownloadedSongs; // r6
MusicDownloadManager *v9; // r0
MusicDownloadManager *v10; // r0
MusicDownloadManager *v11; // r7
MusicDownloadManager *v12; // r0
MusicDownloadManager *v13; // r0
result = (*(int (__fastcall **)(FLAlertLayer *))(*(_DWORD *)a2 + 32))(a2);
if ( result == 1 && a3 )
{
v6 = (MusicDownloadManager *)MusicDownloadManager::sharedState((MusicDownloadManager *)((char *)&dword_0 + 1));
v7 = 0;
DownloadedSongs = (cocos2d::CCArray *)MusicDownloadManager::getDownloadedSongs(v6);
while ( 1 )
{
v9 = (MusicDownloadManager *)cocos2d::CCArray::count(DownloadedSongs);
if ( v7 >= (unsigned int)v9 )
break;
v10 = (MusicDownloadManager *)cocos2d::CCArray::objectAtIndex(DownloadedSongs, v7++);
v11 = v10;
v12 = (MusicDownloadManager *)MusicDownloadManager::sharedState(v10);
MusicDownloadManager::deleteSong(v12, *((_DWORD *)v11 + 66));
}
v13 = (MusicDownloadManager *)MusicDownloadManager::sharedState(v9);
MusicDownloadManager::clearUnusedSongs(v13);
return (*(int (__fastcall **)(GJSongBrowser *, _DWORD))(*(_DWORD *)this + 660))(this, 0);
}
return result;
}