//
// MusicDownloadManager::onGetSongInfoCompleted from 0x45c6b4 to 0x45c782 (206 bytes)
//
// 1 xrefs:
// > MusicDownloadManager::handleIt @ 0x45c7d8
//
// 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
//
void __fastcall MusicDownloadManager::onGetSongInfoCompleted(MusicDownloadManager *a1, int a2, const char **a3, int a4)
{
int v6; // r7
const char *SongInfoKey; // r0
int v8; // r10
MusicDownloadManager *v9; // r0
int v10; // r9
int v11; // r1
GJSongError v12; // r2
stl::StringData::Internal *v13; // r2
stl::StringData::Internal *v14; // r3
SongInfoObject *v15; // r8
_DWORD v16[2]; // [sp+8h] [bp-8h] BYREF
v16[0] = a3;
v16[1] = a4;
v6 = atoi(*a3);
SongInfoKey = MusicDownloadManager::getSongInfoKey(a1, v6);
MusicDownloadManager::removeDLFromActive(a1, SongInfoKey);
sub_776584((int)v16, "-1");
v8 = sub_774DBC(a2, v16);
sub_774008(v16);
if ( !v8 )
{
v9 = a1;
goto LABEL_6;
}
sub_776584((int)v16, "-2");
v10 = sub_774DBC(a2, v16);
sub_774008(v16);
if ( !v10 )
{
v9 = a1;
v11 = v6;
v12 = NotAllowed;
LABEL_7:
MusicDownloadManager::loadSongInfoFailed(v9, v11, v12);
return;
}
sub_775C20(v16);
v15 = MusicDownloadManager::addSongObjectFromString((int)a1, (int)v16, v13, v14);
sub_774008(v16);
v9 = a1;
if ( !v15 )
{
LABEL_6:
v11 = v6;
v12 = FailedToFetch;
goto LABEL_7;
}
MusicDownloadManager::loadSongInfoFinished(a1, v15);
}