//
// InfoLayer::keyDown from 0x540a9c to 0x540b46 (170 bytes)
//
// 1 xrefs:
// > `non-virtual thunk to'InfoLayer::keyDown @ 0x540b4a
//
// 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:52:18 +0000
//
GameLevelManager *__fastcall InfoLayer::keyDown(InfoLayer *a1, int a2)
{
cocos2d::CCDirector *v4; // r0
int v5; // r0
cocos2d::CCDirector *v6; // r0
int v7; // r0
int v8; // r0
cocos2d::CCDirector *v9; // r0
int v10; // r0
int v11; // r3
cocos2d::CCArray *v12; // r0
int v14; // r0
v4 = (cocos2d::CCDirector *)InfoLayer::canBulkDelete(a1);
if ( v4 && a2 == 65 )
{
v5 = cocos2d::CCDirector::sharedDirector(v4);
v6 = (cocos2d::CCDirector *)(*(int (__fastcall **)(int))(*(_DWORD *)v5 + 96))(v5);
if ( *((_BYTE *)v6 + 89)
|| (v7 = cocos2d::CCDirector::sharedDirector(v6),
*(_BYTE *)((*(int (__fastcall **)(int))(*(_DWORD *)v7 + 96))(v7) + 91)) )
{
v11 = *((_DWORD *)a1 + 162);
if ( v11 )
{
v12 = *(cocos2d::CCArray **)(v11 + 328);
if ( v12 )
{
if ( cocos2d::CCArray::count(v12) )
return InfoLayer::onBulkSelectAll(a1, nullptr);
}
}
}
return FLAlertLayer::keyDown(a1, a2);
}
if ( a2 != 82 )
return FLAlertLayer::keyDown(a1, a2);
v8 = cocos2d::CCDirector::sharedDirector(v4);
v9 = (cocos2d::CCDirector *)(*(int (__fastcall **)(int))(*(_DWORD *)v8 + 96))(v8);
if ( !*((_BYTE *)v9 + 89) )
{
v10 = cocos2d::CCDirector::sharedDirector(v9);
if ( !*(_BYTE *)((*(int (__fastcall **)(int))(*(_DWORD *)v10 + 96))(v10) + 91) )
return FLAlertLayer::keyDown(a1, a2);
}
v14 = *((_DWORD *)a1 + 153);
if ( !v14 || !(*(int (__fastcall **)(int))(*(_DWORD *)v14 + 176))(v14) )
return FLAlertLayer::keyDown(a1, a2);
return InfoLayer::onRefreshComments(a1, nullptr);
}