mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-25 06:06:21 +00:00
Moved handle_lost_connection and handle_failed_login to server_events
This commit is contained in:
@@ -20,8 +20,10 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "chat_session.h"
|
||||
#include "log.h"
|
||||
#include "muc.h"
|
||||
#include "roster_list.h"
|
||||
#include "ui/ui.h"
|
||||
|
||||
void
|
||||
@@ -55,3 +57,22 @@ handle_login_account_success(char *account_name)
|
||||
accounts_free_account(account);
|
||||
}
|
||||
|
||||
void
|
||||
handle_lost_connection(void)
|
||||
{
|
||||
cons_show_error("Lost connection.");
|
||||
roster_clear();
|
||||
muc_clear_invites();
|
||||
chat_sessions_clear();
|
||||
ui_disconnected();
|
||||
ui_current_page_off();
|
||||
}
|
||||
|
||||
void
|
||||
handle_failed_login(void)
|
||||
{
|
||||
cons_show_error("Login failed.");
|
||||
log_info("Login failed");
|
||||
ui_current_page_off();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user