//
// CustomSongWidget::updateSongObject from 0x1006f9a30 to 0x1006f9ac1 (145 bytes)
//
// 6 xrefs:
// > CustomSongLayer::onSearch @ 0x1001f9173
// > CustomSongLayer::dropDownLayerWillClose @ 0x1001f995e
// > sub_1001F9970 @ 0x1001f99b5
// > CustomSongLayer::musicBrowserClosed @ 0x1001f9a0e
// > sub_1001F9A20 @ 0x1001f9a65
// > SongSelectNode::onSongMode @ 0x1001fcc00
//
// 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 12:35:55 +0000
//
__int64 __fastcall CustomSongWidget::updateSongObject(__int64 a1, __int64 a2)
{
__int64 v2; // r14
__int64 v4; // rdi
_DWORD *v5; // rdi
int v6; // eax
v2 = a2;
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 376) + 344LL))(*(_QWORD *)(a1 + 376), 0);
v4 = *(_QWORD *)(a1 + 480);
if ( v4 )
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v4 + 344LL))(v4, 0);
v5 = *(_DWORD **)(a1 + 336);
if ( v5 != (_DWORD *)a2 )
{
if ( a2 )
{
cocos2d::CCObject::retain(a2);
v5 = *(_DWORD **)(a1 + 336);
}
if ( v5 )
cocos2d::CCObject::release(v5);
*(_QWORD *)(a1 + 336) = a2;
if ( a2 )
goto LABEL_9;
LABEL_11:
v6 = 0;
goto LABEL_12;
}
v2 = *(_QWORD *)(a1 + 336);
if ( !v5 )
goto LABEL_11;
LABEL_9:
v6 = *(_DWORD *)(v2 + 316);
LABEL_12:
*(_DWORD *)(a1 + 504) = v6;
return CustomSongWidget::updateSongInfo(a1);
}