//
// LevelBrowserLayer::onToggleAllObjects from 0x6e6aa0 to 0x6e6b34 (148 bytes)
//
// 3 xrefs:
// > ??> @ 0x869d0
// > LevelBrowserLayer::init @ 0x6ebc58
// > ??> @ 0x122c8b8
//
// 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 LevelBrowserLayer::onToggleAllObjects(LevelBrowserLayer *a1, cocos2d::CCObject *a2)
{
bool m_allSelected; // w1
cocos2d::CCArray *m_levels; // x0
cocos2d::CCArray *v5; // x0
cocos2d::ccArray *data; // x0
unsigned int num; // w1
cocos2d::CCObject **arr; // x0
cocos2d::CCObject **i; // x3
cocos2d::CCObject *v10; // x1
m_allSelected = a1->m_allSelected;
m_levels = a1->m_levels;
a1->m_allSelected = !m_allSelected;
if ( m_levels && (unsigned int)cocos2d::CCArray::count(m_levels) )
{
v5 = a1->m_levels;
if ( v5 )
{
data = v5->data;
num = data->num;
if ( data->num )
{
arr = data->arr;
for ( i = &arr[num - 1]; i >= arr; HIBYTE(v10[9].__vftable) = a1->m_allSelected )
{
v10 = *arr;
if ( !*arr )
break;
++arr;
}
}
}
CustomListView::reloadAll((CustomListView *)a1->m_list->m_listView);
}
}