1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-12-04 14:46:46 -05:00

Open new window when otr session started by contact

fixes #331
This commit is contained in:
James Booth 2014-04-19 00:03:11 +01:00
parent 8f2c0a66bf
commit 71aea78e90

View File

@ -751,7 +751,10 @@ static void
_ui_gone_secure(const char * const recipient, gboolean trusted)
{
ProfWin *window = wins_get_by_recipient(recipient);
if (window != NULL) {
if (window == NULL) {
window = wins_new(recipient, WIN_CHAT);
}
window->is_otr = TRUE;
window->is_trusted = trusted;
if (trusted) {
@ -765,7 +768,9 @@ _ui_gone_secure(const char * const recipient, gboolean trusted)
title_bar_set_recipient(recipient_str->str);
g_string_free(recipient_str, TRUE);
win_update_virtual(window);
}
} else {
int num = wins_get_num(window);
status_bar_new(num);
}
}