//
// SFXBrowser::updatePageLabel from 0x6c4b64 to 0x6c4c62 (254 bytes)
//
// 1 xrefs:
// > SFXBrowser::setupList @ 0x6c62fe
//
// 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:56:53 +0000
//
int __fastcall SFXBrowser::updatePageLabel(SFXBrowser *this, int a2, char *a3, int a4)
{
int v5; // r0
int v6; // r6
int v7; // r8
int v8; // r2
int v9; // r1
int v10; // r2
const char *v11; // r1
cocos2d::CCString *v12; // r0
char *CString; // r1
char *v14; // r1
SFXBrowser *v16; // [sp+0h] [bp-10h] BYREF
int v17; // [sp+4h] [bp-Ch]
char *v18; // [sp+8h] [bp-8h]
int v19; // [sp+Ch] [bp-4h]
v16 = this;
v17 = a2;
v18 = a3;
v19 = a4;
v5 = cocos2d::CCArray::count(*(cocos2d::CCArray **)(*((_DWORD *)this + 136) + 56));
v6 = v5;
if ( v5 <= 0 )
v7 = 0;
else
v7 = (int)ceilf((float)((v5 - 1) / *((_DWORD *)this + 191)));
v16 = nullptr;
v17 = 0;
v18 = nullptr;
if ( v6 <= 0 )
{
CString = "No matches";
}
else
{
v8 = *((_DWORD *)this + 191);
v9 = *(_DWORD *)(*((_DWORD *)this + 136) + 72) * v8;
v10 = v8 + v9;
v11 = (const char *)(v9 + 1);
if ( v10 >= v6 )
v10 = v6;
v12 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"%i to %i of %i",
v11,
v10,
v6,
v16,
v17);
CString = (char *)cocos2d::CCString::getCString(v12);
}
std::string::assign((int *)&v16, CString);
if ( ((unsigned __int8)v16 & 1) != 0 )
v14 = v18;
else
v14 = (char *)&v16 + 1;
(*(void (__fastcall **)(_DWORD, char *, int))(**((_DWORD **)this + 146) + 464))(
*((_DWORD *)this + 146),
v14,
(unsigned __int8)v16 << 31);
(*(void (__fastcall **)(_DWORD, bool))(**((_DWORD **)this + 147) + 172))(
*((_DWORD *)this + 147),
*(_DWORD *)(*((_DWORD *)this + 136) + 72) > 0);
(*(void (__fastcall **)(_DWORD, bool))(**((_DWORD **)this + 148) + 172))(
*((_DWORD *)this + 148),
*(_DWORD *)(*((_DWORD *)this + 136) + 72) < v7);
return std::string::~string((int)&v16);
}