mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-24 07:46:21 +00:00
Show message in private windows when user offline
This commit is contained in:
@@ -183,6 +183,10 @@ cl_ev_send_muc_msg(ProfMucWin *mucwin, const char *const msg)
|
||||
void
|
||||
cl_ev_send_priv_msg(ProfPrivateWin *privwin, const char *const msg)
|
||||
{
|
||||
message_send_private(privwin->fulljid, msg);
|
||||
privwin_outgoing_msg(privwin, msg);
|
||||
if (privwin->occupant_offline) {
|
||||
privwin_message_occupant_offline(privwin);
|
||||
} else {
|
||||
message_send_private(privwin->fulljid, msg);
|
||||
privwin_outgoing_msg(privwin, msg);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -665,6 +665,14 @@ sv_ev_room_occupant_offline(const char *const room, const char *const nick,
|
||||
mucwin_occupant_offline(mucwin, nick);
|
||||
}
|
||||
prefs_free_string(muc_status_pref);
|
||||
|
||||
Jid *jidp = jid_create_from_bare_and_resource(room, nick);
|
||||
ProfPrivateWin *privwin = wins_get_private(jidp->fulljid);
|
||||
jid_destroy(jidp);
|
||||
if (privwin != NULL) {
|
||||
privwin_occupant_offline(privwin);
|
||||
}
|
||||
|
||||
occupantswin_occupants(room);
|
||||
rosterwin_roster();
|
||||
}
|
||||
@@ -840,6 +848,14 @@ sv_ev_muc_occupant_online(const char *const room, const char *const nick, const
|
||||
mucwin_occupant_online(mucwin, nick, role, affiliation, show, status);
|
||||
}
|
||||
prefs_free_string(muc_status_pref);
|
||||
|
||||
Jid *jidp = jid_create_from_bare_and_resource(mucwin->roomjid, nick);
|
||||
ProfPrivateWin *privwin = wins_get_private(jidp->fulljid);
|
||||
jid_destroy(jidp);
|
||||
if (privwin) {
|
||||
privwin_occupant_online(privwin);
|
||||
}
|
||||
|
||||
occupantswin_occupants(room);
|
||||
rosterwin_roster();
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user