//
// ThreadMessageOptionsPopup::onAction from 0x1400e5a50 to 0x1400e5c03 (435 bytes)
//
// 2 xrefs:
// > ThreadMessageOptionsPopup::init @ 0x1400e5982
// > ??> @ 0x140914c60
//
// This function is hookable on this platform (idp: pc, 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 11:26:32 +0000
//
// Hidden C++ exception states: #wind=1
__int64 __fastcall ThreadMessageOptionsPopup::onAction(__int64 a1)
{
__int64 v2; // rcx
int v3; // ebx
__int64 v4; // rax
cocos2d::CCObject *v5; // rbx
char *v7; // rax
__int128 v8; // [rsp+50h] [rbp-48h] BYREF
__int64 v9; // [rsp+60h] [rbp-38h]
__int64 v10; // [rsp+68h] [rbp-30h]
_BYTE v11[40]; // [rsp+70h] [rbp-28h] BYREF
if ( *(_BYTE *)(a1 + 1056) )
{
ThreadViewPopup::requestDeleteMessage(*(_QWORD *)(a1 + 1016), *(_QWORD *)(*(_QWORD *)(a1 + 1008) + 56LL));
return (*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 1104LL))(a1, 0);
}
v2 = *(_QWORD *)(a1 + 1016);
if ( !*(_BYTE *)(v2 + 783) )
{
v7 = ReportPopup::createForThread(*(_QWORD *)(v2 + 744), *(_QWORD **)(a1 + 1008), (size_t *)(a1 + 1024));
if ( v7 )
(*(void (__fastcall **)(char *))(*(_QWORD *)v7 + 1064LL))(v7);
return (*(__int64 (__fastcall **)(__int64, _QWORD))(*(_QWORD *)a1 + 1104LL))(a1, 0);
}
v3 = a1 + 1000;
if ( !a1 )
v3 = 0;
v8 = 0;
*(_QWORD *)&v8 = sub_14003D460(0x30u);
v9 = 41;
v10 = 47;
strcpy((char *)v8, "Delete this message for everyone?");
v4 = sub_14003F4F0((__int64)v11, (__int64)&v8);
v5 = FLAlertLayer::create(
v3,
(int)&qword_140720400,
v4,
(__int64)"Cancel",
(__int64)"Delete",
1136525312,
0,
0,
1065353216);
sub_14003D310((__int64)&v8);
(*(void (__fastcall **)(cocos2d::CCObject *, __int64))(*(_QWORD *)v5 + 64LL))(v5, 12);
return (*(__int64 (__fastcall **)(cocos2d::CCObject *))(*(_QWORD *)v5 + 1064LL))(v5);
}