mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-08-04 20:56:22 +00:00
Offline contacts presence notifications now in contact list
Can send messages to offline contacts
This commit is contained in:
@@ -157,7 +157,7 @@ prof_handle_contact_online(char *contact, char *show, char *status)
|
||||
void
|
||||
prof_handle_contact_offline(char *contact, char *show, char *status)
|
||||
{
|
||||
gboolean result = contact_list_remove(contact);
|
||||
gboolean result = contact_list_add(contact, "offline", status);
|
||||
if (result) {
|
||||
win_contact_offline(contact, show, status);
|
||||
}
|
||||
|
||||
@@ -563,9 +563,11 @@ cons_show_online_contacts(GSList *list)
|
||||
|
||||
while(curr) {
|
||||
PContact contact = curr->data;
|
||||
_win_show_time(_cons_win);
|
||||
const char *show = p_contact_show(contact);
|
||||
|
||||
if (strcmp(show, "offline") != 0) {
|
||||
_win_show_time(_cons_win);
|
||||
|
||||
if (strcmp(show, "online") == 0) {
|
||||
wattron(_cons_win, COLOUR_ONLINE);
|
||||
} else if (strcmp(show, "away") == 0) {
|
||||
@@ -601,6 +603,7 @@ cons_show_online_contacts(GSList *list)
|
||||
} else {
|
||||
wattroff(_cons_win, COLOUR_OFFLINE);
|
||||
}
|
||||
}
|
||||
|
||||
curr = g_slist_next(curr);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user