//
// ThreadViewPopup::refreshLockNotice from 0x752918 to 0x752dba (1186 bytes)
//
// 8 xrefs:
// > ThreadOptionsPopup::threadUpdateFinished @ 0x752f7a
// > ThreadViewPopup::exitSearch @ 0x75bdbc
// > ThreadViewPopup::init @ 0x75cd8e
// > ThreadViewPopup::threadSendFinished @ 0x75dfa2
// > ThreadViewPopup::threadSendFinished @ 0x75e0a8
// > ThreadViewPopup::threadMessagesFinished @ 0x75e3ec
// > ThreadViewPopup::threadMessagesFinished @ 0x75e488
// > ThreadViewPopup::threadMessagesFinished @ 0x75ed42
//
// 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:58:52 +0000
//
ThreadViewPopup *__fastcall ThreadViewPopup::refreshLockNotice(ThreadViewPopup *this, int a2, const char *a3)
{
ThreadViewPopup *v3; // r4
int v4; // r8
int v5; // r5
int v6; // r0
int v7; // r0
int v8; // r0
int v9; // r0
int v10; // r0
int v11; // r0
int v12; // r0
int v13; // r0
int v14; // r0
int v15; // r3
int v16; // r6
char *v17; // r9
const char *v18; // r0
const char *v19; // r11
size_t v20; // r0
char *v21; // r11
size_t v22; // r0
int v23; // r2
char *v24; // r1
const char *v25; // r1
int v26; // r0
int v27; // r6
void (__fastcall *v28)(int, _BYTE *); // r9
const char *CString; // r1
int v30; // r2
int v31; // r1
int v32; // r3
int v33; // r3
char *v34; // r0
int v35; // r3
cocos2d::CCString *v36; // r0
int v37; // r3
int v38; // r3
char *v39; // r9
int v40; // r3
int v41; // r3
char *v42; // r6
float v43; // s17
int v44; // r0
int v45; // r6
void (__fastcall *v46)(int, _BYTE *); // r9
float v47; // s15
float v48; // s16
float v49; // r0
_BYTE v50[8]; // [sp+Ch] [bp-28h] BYREF
int v51[3]; // [sp+14h] [bp-20h] BYREF
int v52; // [sp+20h] [bp-14h] BYREF
int v53; // [sp+24h] [bp-10h]
int v54; // [sp+28h] [bp-Ch]
v3 = this;
v4 = *((unsigned __int8 *)this + 808);
if ( *((_BYTE *)this + 808) )
return this;
if ( *((_BYTE *)this + 599) || ThreadViewPopup::removedView(this) || *(_BYTE *)(*((_DWORD *)v3 + 141) + 176) )
v5 = 1;
else
v5 = ThreadViewPopup::dmSendBlocked(v3);
v6 = *((_DWORD *)v3 + 223);
if ( v6 )
(*(void (__fastcall **)(int, int))(*(_DWORD *)v6 + 172))(v6, (unsigned __int8)v5 ^ 1);
v7 = *((_DWORD *)v3 + 224);
if ( v7 )
(*(void (__fastcall **)(int, int))(*(_DWORD *)v7 + 172))(v7, (unsigned __int8)v5 ^ 1);
v8 = *((_DWORD *)v3 + 186);
if ( v8 )
(*(void (__fastcall **)(int, int))(*(_DWORD *)v8 + 172))(v8, (unsigned __int8)v5 ^ 1);
v9 = *((_DWORD *)v3 + 169);
if ( v9 )
(*(void (__fastcall **)(int, int))(*(_DWORD *)v9 + 172))(v9, (unsigned __int8)v5 ^ 1);
v10 = *((_DWORD *)v3 + 187);
if ( v10 )
{
if ( !v5 )
goto LABEL_21;
(*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v10 + 172))(v10, 0);
}
else if ( !v5 )
{
goto LABEL_21;
}
v11 = *((_DWORD *)v3 + 170);
if ( v11 )
(*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v11 + 684))(v11, 0);
LABEL_21:
v12 = *((_DWORD *)v3 + 171);
if ( v12 )
{
if ( v5 )
(*(void (__fastcall **)(int, _DWORD))(*(_DWORD *)v12 + 580))(v12, 0);
(*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)v3 + 171) + 172))(
*((_DWORD *)v3 + 171),
(unsigned __int8)v5 ^ 1);
(*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)v3 + 171) + 500))(
*((_DWORD *)v3 + 171),
(unsigned __int8)v5 ^ 1);
}
v13 = *((_DWORD *)v3 + 169);
if ( v13 )
{
v14 = (*(int (__fastcall **)(int))(*(_DWORD *)v13 + 536))(v13);
v15 = *((_DWORD *)v3 + 141);
v16 = *(unsigned __int8 *)(v15 + 168);
v17 = (char *)v14;
if ( *(_BYTE *)(v15 + 168) )
v16 = *(_DWORD *)(v15 + 172) == 1;
v18 = (const char *)(*(int (__fastcall **)(_DWORD))(**(_DWORD **)(v14 + 536) + 472))(*(_DWORD *)(v14 + 536));
v52 = 0;
v53 = 0;
v54 = 0;
v19 = v18;
v20 = strlen(v18);
std::string::__init(&v52, v19, v20);
if ( v16 )
v21 = "Req";
else
v21 = "Send";
v22 = strlen(v21);
if ( (v52 & 1) != 0 )
v23 = v53;
else
v23 = (int)(unsigned __int8)v52 >> 1;
if ( v22 == v23 )
v4 = std::string::compare((unsigned __int8 *)&v52, 0, 0xFFFFFFFF, v21, v22) == 0;
std::string::~string((int)&v52);
if ( !v4 )
{
if ( v16 )
v24 = "Req";
else
v24 = "Send";
ButtonSprite::setString((int)v17, v24);
if ( v16 )
v25 = "GJ_button_05.png";
else
v25 = "GJ_button_01.png";
ButtonSprite::updateBGImage(v17, v25);
}
}
if ( !*((_DWORD *)v3 + 152) )
{
v26 = cocos2d::CCLabelBMFont::create((cocos2d::CCLabelBMFont *)&unk_B6B226, "goldFont.fnt", a3);
*((_DWORD *)v3 + 152) = v26;
(*(void (__fastcall **)(int, int))(*(_DWORD *)v26 + 80))(v26, 1056964608);
v27 = *((_DWORD *)v3 + 152);
v28 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v27 + 92);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v50, *((float *)v3 + 159), *((float *)v3 + 193) + 14.0);
v28(v27, v50);
(*(void (__fastcall **)(_DWORD, _DWORD, int))(**((_DWORD **)v3 + 115) + 232))(
*((_DWORD *)v3 + 115),
*((_DWORD *)v3 + 152),
6);
}
if ( *((_BYTE *)v3 + 599) )
{
if ( *(_BYTE *)(*((_DWORD *)v3 + 141) + 176) )
CString = "Locked. Moderator view.";
else
CString = "Moderator view.";
}
else if ( ThreadViewPopup::removedView(v3) )
{
CString = "You were removed from this group chat.";
}
else
{
v31 = *((_DWORD *)v3 + 141);
if ( *(_BYTE *)(v31 + 176) )
{
CString = "This conversation has been locked.";
}
else
{
v32 = *(_DWORD *)(v31 + 172);
if ( v32 == 4 )
{
v33 = *(unsigned __int8 *)(v31 + 60);
v30 = v33 << 31;
if ( (v33 & 1) == 0 )
v31 += 61;
v34 = "%s only accepts messages from friends.";
if ( (v33 & 1) != 0 )
v31 = *(_DWORD *)(v31 + 68);
}
else
{
if ( v32 != 5 )
{
if ( v32 == 7 )
CString = "You can't message this user.";
else
CString = "Message request pending.";
goto LABEL_69;
}
v35 = *(unsigned __int8 *)(v31 + 60) << 31;
if ( (*(_BYTE *)(v31 + 60) & 1) == 0 )
v31 += 61;
v34 = "%s has messages turned off.";
if ( v35 < 0 )
v31 = *(_DWORD *)(v31 + 68);
}
v36 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)v34, (const char *)v31, v30);
CString = (const char *)cocos2d::CCString::getCString(v36);
}
}
LABEL_69:
(*(void (__fastcall **)(_DWORD, const char *))(**((_DWORD **)v3 + 152) + 464))(*((_DWORD *)v3 + 152), CString);
cocos2d::CCLabelBMFont::limitLabelWidth(*((cocos2d::CCLabelBMFont **)v3 + 152), *((float *)v3 + 157) - 40.0, 0.5, 0.3);
(*(void (__fastcall **)(_DWORD, int))(**((_DWORD **)v3 + 152) + 172))(*((_DWORD *)v3 + 152), v5);
if ( !*((_DWORD *)v3 + 153) )
{
memset(v51, 0, sizeof(v51));
std::string::__init(v51, &unk_B6B226, 0);
v52 = 0;
v53 = 0;
v54 = 0;
std::string::__init(&v52, &unk_B6B226, 0);
*((_DWORD *)v3 + 153) = InfoAlertButton::create((char *)v51, (int)&v52, 1056964608);
std::string::~string((int)&v52);
std::string::~string((int)v51);
CCMenuItemSpriteExtra::setSizeMult(*((_DWORD *)v3 + 153), 1.5);
(*(void (__fastcall **)(_DWORD, _DWORD))(**((_DWORD **)v3 + 111) + 228))(
*((_DWORD *)v3 + 111),
*((_DWORD *)v3 + 153));
}
if ( *((_BYTE *)v3 + 599) )
{
v39 = "Moderator View";
}
else if ( ThreadViewPopup::removedView(v3) )
{
v39 = "Removed";
}
else
{
v37 = *((_DWORD *)v3 + 141);
if ( *(_BYTE *)(v37 + 176) )
{
v39 = "Conversation Locked";
}
else
{
v38 = *(_DWORD *)(v37 + 172);
switch ( v38 )
{
case 4:
v39 = "Friends Only";
break;
case 5:
v39 = "Messages Off";
break;
case 7:
v39 = "Blocked";
break;
default:
v39 = "Request Pending";
break;
}
}
}
if ( *((_BYTE *)v3 + 599) )
{
v42 = "You are reading this conversation as a moderator.\nParticipants cannot see this and nothing is marked read.";
}
else if ( ThreadViewPopup::removedView(v3) )
{
v42 = "The owner removed you from this group chat.\n"
"You can still read messages sent before you were removed.\n"
"You cannot see new messages or send messages.\n"
"You can remove the group chat from the options menu when you are done.";
}
else
{
v40 = *((_DWORD *)v3 + 141);
if ( *(_BYTE *)(v40 + 176) )
{
v42 = "A moderator locked this conversation.\nIt can still be read, but no new messages can be sent.";
}
else
{
v41 = *(_DWORD *)(v40 + 172);
switch ( v41 )
{
case 4:
v42 = "This user only accepts messages from friends.\nSend a friend request to message them.";
break;
case 5:
v42 = "This user has turned messages off.\nYou can read the conversation but not reply.";
break;
case 7:
v42 = "Messages between you and this user are blocked.";
break;
default:
v42 = "Your message was sent as a request.\nYou can write again once they reply.";
break;
}
}
}
std::string::assign((int *)(*((_DWORD *)v3 + 153) + 392), v39);
std::string::assign((int *)(*((_DWORD *)v3 + 153) + 404), v42);
v43 = *(float *)(*(int (__fastcall **)(_DWORD))(**((_DWORD **)v3 + 152) + 164))(*((_DWORD *)v3 + 152));
v44 = (*(int (__fastcall **)(_DWORD))(**((_DWORD **)v3 + 152) + 84))(*((_DWORD *)v3 + 152));
v45 = *((_DWORD *)v3 + 153);
v46 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v45 + 92);
v47 = *(float *)&v44;
v48 = COERCE_FLOAT((*(int (__fastcall **)(_DWORD))(**((_DWORD **)v3 + 152) + 112))(*((_DWORD *)v3 + 152)));
v49 = (*(float (__fastcall **)(_DWORD))(**((_DWORD **)v3 + 152) + 120))(*((_DWORD *)v3 + 152));
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v50, (float)(v48 + (float)((float)(v43 * v47) * 0.5)) + 12.0, v49);
v46(v45, v50);
return (ThreadViewPopup *)(*(int (__fastcall **)(_DWORD, int))(**((_DWORD **)v3 + 153) + 172))(
*((_DWORD *)v3 + 153),
v5);
}