summaryrefslogtreecommitdiff
path: root/src/irc/irc-server.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2005-01-23 02:14:37 +0000
committerSebastien Helleu <flashcode@flashtux.org>2005-01-23 02:14:37 +0000
commit9d0b6fad72c3381af5397ee3549f9987194892aa (patch)
treecf10b9098baff3beba4bc582944e7d8183efe42d /src/irc/irc-server.c
parent63d6ee1007d7038cbd4f86f41909cab67f5d0152 (diff)
downloadweechat-9d0b6fad72c3381af5397ee3549f9987194892aa.zip
Added lag indicator
Diffstat (limited to 'src/irc/irc-server.c')
-rw-r--r--src/irc/irc-server.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/irc/irc-server.c b/src/irc/irc-server.c
index b3afa302f..680ebc98e 100644
--- a/src/irc/irc-server.c
+++ b/src/irc/irc-server.c
@@ -84,6 +84,10 @@ server_init (t_irc_server *server)
server->away_time = 0;
server->server_read = -1;
server->server_write = -1;
+ server->lag = 0;
+ server->lag_check_time.tv_sec = 0;
+ server->lag_check_time.tv_usec = 0;
+ server->lag_next_check = 0;
server->buffer = NULL;
server->channels = NULL;
server->last_channel = NULL;
@@ -818,8 +822,6 @@ server_disconnect (t_irc_server *server, int reconnect)
irc_display_prefix (ptr_channel->buffer, PREFIX_INFO);
gui_printf (ptr_channel->buffer, _("Disconnected from server!\n"));
}
- gui_draw_buffer_nick (gui_current_window->buffer, 1);
- gui_draw_buffer_status (gui_current_window->buffer, 1);
}
/* close communication with server */
@@ -839,6 +841,10 @@ server_disconnect (t_irc_server *server, int reconnect)
server->is_connected = 0;
server->is_away = 0;
server->away_time = 0;
+ server->lag = 0;
+ server->lag_check_time.tv_sec = 0;
+ server->lag_check_time.tv_usec = 0;
+ server->lag_next_check = 0;
if ((reconnect) && (server->autoreconnect))
{
@@ -849,6 +855,8 @@ server_disconnect (t_irc_server *server, int reconnect)
}
else
server->reconnect_start = 0;
+
+ gui_redraw_buffer (gui_current_window->buffer);
}
/*