//
// EditorOptionsLayer::onButtonsPerRow from 0xa1c930 to 0xa1c9b8 (136 bytes)
//
// 4 xrefs:
// > ??> @ 0xd33d8
// > EditorOptionsLayer::setupOptions @ 0xa35874
// > EditorOptionsLayer::setupOptions @ 0xa35950
// > ??> @ 0x1546428
//
// This function is hookable on this platform (idp: arm, 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:59:38 +0000
//
__int64 __fastcall EditorOptionsLayer::onButtonsPerRow(EditorOptionsLayer *this, cocos2d::CCObject *a2)
{
int v3; // w0
int v4; // w1
unsigned __int64 v5; // x1
__int64 v6; // x20
__int64 (__fastcall *v7)(__int64, __int64); // x19
cocos2d::CCString *v8; // x0
__int64 CString; // x0
v3 = (*(__int64 (__fastcall **)(cocos2d::CCObject *))(*(_QWORD *)a2 + 64LL))(a2);
v4 = *((_DWORD *)this + 280);
if ( v3 == 1 )
LODWORD(v5) = v4 + 1;
else
LODWORD(v5) = v4 - 1;
if ( (int)v5 < 6 )
LODWORD(v5) = 6;
v6 = *((_QWORD *)this + 141);
if ( (int)v5 > 12 )
v5 = 12;
else
v5 = (unsigned int)v5;
*((_DWORD *)this + 280) = v5;
v7 = *(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v6 + 928LL);
v8 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"%i", (const char *)v5);
CString = cocos2d::CCString::getCString(v8);
return v7(v6, CString);
}