mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-26 23:43:29 +01:00
fix
This commit is contained in:
parent
5c66f5c161
commit
7eebbd982d
@ -579,7 +579,7 @@ static void chat_onGroupInvite(ToxWindow *self, Tox *m, int32_t friendnumber, co
|
|||||||
Friends.list[friendnumber].group_invite.pending = true;
|
Friends.list[friendnumber].group_invite.pending = true;
|
||||||
Friends.list[friendnumber].group_invite.length = length;
|
Friends.list[friendnumber].group_invite.length = length;
|
||||||
|
|
||||||
char name[TOX_MAX_NAME_LENGTH + 1];
|
char name[TOX_MAX_NAME_LENGTH];
|
||||||
get_nick_truncate(m, name, friendnumber);
|
get_nick_truncate(m, name, friendnumber);
|
||||||
|
|
||||||
sound_notify(self, generic_message, NT_WNDALERT_2, NULL);
|
sound_notify(self, generic_message, NT_WNDALERT_2, NULL);
|
||||||
|
@ -147,8 +147,8 @@ static void groupchat_onGroupMessage(ToxWindow *self, Tox *m, int groupnum, int
|
|||||||
|
|
||||||
int nick_clr = strcmp(nick, selfnick) == 0 ? GREEN : CYAN;
|
int nick_clr = strcmp(nick, selfnick) == 0 ? GREEN : CYAN;
|
||||||
|
|
||||||
/* Only play sound if mentioned */
|
/* Only play sound if mentioned by someone else */
|
||||||
if (strcasestr(msg, selfnick)) {
|
if (strcasestr(msg, selfnick) && strcmp(selfnick, nick)) {
|
||||||
sound_notify(self, generic_message, NT_WNDALERT_0, NULL);
|
sound_notify(self, generic_message, NT_WNDALERT_0, NULL);
|
||||||
|
|
||||||
if (self->active_box != -1)
|
if (self->active_box != -1)
|
||||||
|
@ -104,7 +104,7 @@ void on_action(Tox *m, int32_t friendnumber, const uint8_t *string, uint16_t len
|
|||||||
|
|
||||||
for (i = 0; i < MAX_WINDOWS_NUM; ++i) {
|
for (i = 0; i < MAX_WINDOWS_NUM; ++i) {
|
||||||
if (windows[i].onAction != NULL)
|
if (windows[i].onAction != NULL)
|
||||||
windows[i].onAction(&windows[i], m, friendnumber, (const char *) string, length);
|
windows[i].onAction(&windows[i], m, friendnumber, msg, length);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user