Mercurial > pidgin.yaz
comparison gtk/gtkconn.c @ 14722:51685370de57
[gaim-migrate @ 17476]
Implement the network manager stuff for wingaim.
Also, fix some assertions and fix the freeing of the autorecon data without removing it from the hash.
committer: Tailor Script <tailor@pidgin.im>
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Fri, 13 Oct 2006 02:31:36 +0000 |
parents | 05c34aabdcc3 |
children | 18d1c7cbb352 |
comparison
equal
deleted
inserted
replaced
14721:90882b641dda | 14722:51685370de57 |
---|---|
77 | 77 |
78 if (gtkblist != NULL) | 78 if (gtkblist != NULL) |
79 gtk_gaim_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), | 79 gtk_gaim_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), |
80 (gaim_connections_get_connecting() != NULL)); | 80 (gaim_connections_get_connecting() != NULL)); |
81 | 81 |
82 if (hash != NULL) | 82 g_hash_table_remove(hash, account); |
83 g_hash_table_remove(hash, account); | |
84 | 83 |
85 gaim_gtk_blist_update_account_error_state(account, NULL); | 84 gaim_gtk_blist_update_account_error_state(account, NULL); |
86 } | 85 } |
87 | 86 |
88 static void | 87 static void |
202 if(gtkblist) | 201 if(gtkblist) |
203 gtk_gaim_status_box_set_network_available(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), TRUE); | 202 gtk_gaim_status_box_set_network_available(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), TRUE); |
204 | 203 |
205 while (list) { | 204 while (list) { |
206 GaimAccount *account = (GaimAccount*)list->data; | 205 GaimAccount *account = (GaimAccount*)list->data; |
207 GaimAutoRecon *info = g_hash_table_lookup(hash, account); | 206 g_hash_table_remove(hash, account); |
208 if (info) | 207 if (gaim_account_is_disconnected(account)) |
209 free_auto_recon(info); | 208 do_signon(account); |
210 do_signon(account); | |
211 list = list->next; | 209 list = list->next; |
212 } | 210 } |
213 } | 211 } |
214 | 212 |
215 static void gaim_gtk_connection_network_disconnected () | 213 static void gaim_gtk_connection_network_disconnected () |
220 if(gtkblist) | 218 if(gtkblist) |
221 gtk_gaim_status_box_set_network_available(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), FALSE); | 219 gtk_gaim_status_box_set_network_available(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), FALSE); |
222 | 220 |
223 while (l) { | 221 while (l) { |
224 GaimAccount *a = (GaimAccount*)l->data; | 222 GaimAccount *a = (GaimAccount*)l->data; |
225 gaim_account_disconnect(a); | 223 if (!gaim_account_is_disconnected(a)) |
224 gaim_account_disconnect(a); | |
226 l = l->next; | 225 l = l->next; |
227 } | 226 } |
228 } | 227 } |
229 | 228 |
230 static void gaim_gtk_connection_notice(GaimConnection *gc, const char *text) | 229 static void gaim_gtk_connection_notice(GaimConnection *gc, const char *text) |