//
// FRequestProfilePage::setupCommentsBrowser from 0x1001b7474 to 0x1001b75e8 (372 bytes)
//
// 2 xrefs:
// > FRequestProfilePage::loadPage @ 0x1001b6f0c
// > FRequestProfilePage::loadFRequestsFinished @ 0x1001b7610
//
// 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 __fastcall FRequestProfilePage::setupCommentsBrowser(FRequestProfilePage *a1, cocos2d::CCArray *a2)
{
cocos2d::CCDirector *v4; // x0
cocos2d::CCTouchDispatcher *v5; // x0
cocos2d::CCDirector *v6; // x0
BoomListType v7; // w3
CustomListView *v8; // x0
GJCommentListLayer *v9; // x0
__n128 v10; // q0
GJCommentListLayer *m_listLayer; // x20
__n128 v12; // q1
BoomListView *m_list; // x0
cocos2d::CCMenu *m_buttonMenu; // x19
int v15; // w0
_DWORD v16[4]; // [xsp+0h] [xbp-20h] BYREF
if ( a1->m_listLayer )
{
v4 = cocos2d::CCDirector::sharedDirector();
v5 = (cocos2d::CCTouchDispatcher *)((__int64 (__fastcall *)(cocos2d::CCDirector *))v4->getTouchDispatcher)(v4);
cocos2d::CCTouchDispatcher::unregisterForcePrio(v5, a1->m_listLayer);
((void (__fastcall *)(GJCommentListLayer *))a1->m_listLayer->removeMeAndCleanup)(a1->m_listLayer);
a1->m_listLayer = nullptr;
}
v6 = cocos2d::CCDirector::sharedDirector();
cocos2d::CCDirector::getWinSize(v6);
if ( a2 )
{
if ( a1->m_sent )
v7 = User;
else
v7 = Request;
v8 = CustomListView::create(a2, nullptr, 196.0, 340.0, 0, v7, 0.0);
}
else
{
v8 = nullptr;
}
v9 = GJCommentListLayer::create(v8, "Friend Requests", (cocos2d::ccColor4B)-12684609, 340.0, 196.0, 0);
a1->m_listLayer = v9;
v10 = ((__n128 (__fastcall *)(cocos2d::CCLayer *, GJCommentListLayer *))a1->m_mainLayer->addChild)(
a1->m_mainLayer,
v9);
v10.n128_f32[0] = (float)(*(float *)&v16[2] + -340.0) * 0.5;
m_listLayer = a1->m_listLayer;
v12.n128_f32[0] = (float)((float)((float)(*(float *)&v16[3] + -196.0) * 0.5) + -10.0) + 5.0;
sub_100022980(v10, v12, v16);
((void (__fastcall *)(GJCommentListLayer *, _DWORD *))m_listLayer->setPosition)(m_listLayer, v16);
m_list = a1->m_listLayer->m_list;
if ( m_list )
{
m_buttonMenu = a1->m_buttonMenu;
v15 = ((__int64 (__fastcall *)(BoomListView *))m_list->getTouchPriority)(m_list);
((void (__fastcall *)(cocos2d::CCMenu *, _QWORD))m_buttonMenu->setTouchPriority)(
m_buttonMenu,
(unsigned int)(v15 - 2));
}
}