//
// cocos2d::extension::CCScrollView::initWithViewSize from 0x7af158 to 0x7af266 (270 bytes)
//
// 3 xrefs:
// > cocos2d::extension::CCScrollView::create @ 0x7af29c
// > cocos2d::extension::CCScrollView::init @ 0x7af2fc
// > cocos2d::extension::CCTableView::initWithViewSize @ 0x7af470
//
// 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 12:00:05 +0000
//
cocos2d::CCLayer *__fastcall cocos2d::extension::CCScrollView::initWithViewSize(
int *a1,
const cocos2d::CCSize *a2,
int a3)
{
cocos2d::CCLayer *v6; // r0
cocos2d::CCLayer *v7; // r9
int v8; // r0
int v9; // r7
void (__fastcall *v10)(int, _BYTE *); // r10
cocos2d::CCArray *v11; // r7
int v12; // r10
void (__fastcall *v13)(int, _BYTE *); // r11
int v14; // r3
_BYTE v16[8]; // [sp+4h] [bp-10h] BYREF
v6 = (cocos2d::CCLayer *)cocos2d::CCLayer::init((cocos2d::CCLayer *)a1);
v7 = v6;
if ( v6 )
{
a1[87] = a3;
if ( !a3 )
{
v8 = cocos2d::CCLayer::create(v6);
a1[87] = v8;
(*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v8 + 220))(v8, 0);
v9 = a1[87];
v10 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v9 + 148);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 0.0, 0.0);
v10(v9, v16);
}
cocos2d::CCSize::CCSize((cocos2d::CCSize *)v16, a2);
cocos2d::extension::CCScrollView::setViewSize((cocos2d::CCNode *)a1, (const cocos2d::CCSize *)v16);
(*(void (__fastcall **)(int *, int))(*a1 + 500))(a1, 1);
v11 = (cocos2d::CCArray *)operator new(0x38u);
cocos2d::CCArray::CCArray(v11);
v12 = a1[87];
a1[99] = (int)v11;
*((_BYTE *)a1 + 372) = 1;
*((_BYTE *)a1 + 373) = 1;
a1[82] = 0;
a1[83] = 2;
v13 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v12 + 92);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v16, 0.0, 0.0);
v13(v12, v16);
v14 = *a1;
a1[98] = 0;
(*(void (__fastcall **)(int *, int))(v14 + 228))(a1, a1[87]);
a1[103] = 1065353216;
a1[102] = 1065353216;
std::__tree,std::__map_value_compare,std::less,true>,std::allocator>>::destroy(
(int)(a1 + 109),
(_DWORD *)a1[110]);
a1[111] = 0;
a1[109] = (int)(a1 + 110);
a1[110] = 0;
}
return v7;
}