diff options
author | James Booth <boothj5@gmail.com> | 2015-10-14 00:23:12 +0100 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2015-10-14 00:29:22 +0100 |
commit | c9165ef9d20d1cc96f7edada2a875bc4835b63fb (patch) | |
tree | 65f02b8586d0a547f279cf794f4e3fb0043247fe /src/ui/core.c | |
parent | ecbcecea7d0e20bd7ff12ead58cc4e735c7ee98b (diff) | |
download | profani-tty-c9165ef9d20d1cc96f7edada2a875bc4835b63fb.tar.gz |
Title bar TLS indicator
Issue #616
Diffstat (limited to 'src/ui/core.c')
-rw-r--r-- | src/ui/core.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/ui/core.c b/src/ui/core.c index ff6d90ce..3fda21e8 100644 --- a/src/ui/core.c +++ b/src/ui/core.c @@ -558,12 +558,14 @@ ui_titlebar_presence(contact_presence_t presence) } void -ui_handle_login_account_success(ProfAccount *account) +ui_handle_login_account_success(ProfAccount *account, int secured) { resource_presence_t resource_presence = accounts_get_login_presence(account->name); contact_presence_t contact_presence = contact_presence_from_resource_presence(resource_presence); - cons_show_login_success(account); + cons_show_login_success(account, secured); title_bar_set_presence(contact_presence); + title_bar_set_connected(TRUE); + title_bar_set_tls(secured ? TRUE : FALSE); GString *fulljid = g_string_new(account->jid); g_string_append(fulljid, "/"); @@ -661,6 +663,8 @@ void ui_disconnected(void) { wins_lost_connection(); + title_bar_set_connected(FALSE); + title_bar_set_tls(FALSE); title_bar_set_presence(CONTACT_OFFLINE); status_bar_clear_message(); status_bar_update_virtual(); |