//
// MusicBrowser::onUpdateLibrary from 0x140339be0 to 0x140339c36 (86 bytes)
//
// 2 xrefs:
// > MusicBrowser::init @ 0x140338d79
// > ??> @ 0x1406d5348
//
// 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 MusicBrowser::onUpdateLibrary(MusicBrowser *a1, cocos2d::CCObject *a2)
{
MusicDownloadManager *v3; // rax
MusicDownloadManager *v4; // rax
a1->m_autoUpdating = a2 == nullptr;
if ( MusicDownloadManager::sharedState()->m_customContentURL.m_data.m_size )
{
a1->m_gettingURL = 0;
v4 = MusicDownloadManager::sharedState();
MusicDownloadManager::tryUpdateMusicLibrary(v4);
}
else
{
a1->m_gettingURL = 1;
v3 = MusicDownloadManager::sharedState();
MusicDownloadManager::getCustomContentURL(v3);
}
}