Mercurial > pidgin
comparison src/main.c @ 5874:964e4f94fc56
[gaim-migrate @ 6306]
Moved gaim_account_find() from util.[ch] to gaim_accounts_find() in
account.[ch].
committer: Tailor Script <tailor@pidgin.im>
author | Christian Hammond <chipx86@chipx86.com> |
---|---|
date | Sat, 14 Jun 2003 23:50:24 +0000 |
parents | 059d95c67cda |
children | 448f2f4ca3ec |
comparison
equal
deleted
inserted
replaced
5873:a18e88c4dace | 5874:964e4f94fc56 |
---|---|
235 | 235 |
236 /* if there is more than one user of the same name, then fuck | 236 /* if there is more than one user of the same name, then fuck |
237 * them, they just have to use the account editor to sign in | 237 * them, they just have to use the account editor to sign in |
238 * the second one */ | 238 * the second one */ |
239 | 239 |
240 account = gaim_account_find(username, -1); | 240 account = gaim_accounts_find(username, -1); |
241 if (!account) { | 241 if (!account) { |
242 account = gaim_account_new(username, GAIM_PROTO_DEFAULT); | 242 account = gaim_account_new(username, GAIM_PROTO_DEFAULT); |
243 | 243 |
244 gaim_account_set_remember_password(account, TRUE); | 244 gaim_account_set_remember_password(account, TRUE); |
245 } | 245 } |
263 int retval = -1; | 263 int retval = -1; |
264 | 264 |
265 if (name !=NULL) { /* list of names given */ | 265 if (name !=NULL) { /* list of names given */ |
266 names = g_strsplit(name, ",", 32); | 266 names = g_strsplit(name, ",", 32); |
267 for (n = names; *n != NULL; n++) { | 267 for (n = names; *n != NULL; n++) { |
268 account = gaim_account_find(*n, -1); | 268 account = gaim_accounts_find(*n, -1); |
269 if (account) { /* found a user */ | 269 if (account) { /* found a user */ |
270 if (gaim_account_get_remember_password(account)) { | 270 if (gaim_account_get_remember_password(account)) { |
271 retval = 0; | 271 retval = 0; |
272 serv_login(account); | 272 serv_login(account); |
273 } | 273 } |
302 static void combo_changed(GtkWidget *w, GtkWidget *combo) | 302 static void combo_changed(GtkWidget *w, GtkWidget *combo) |
303 { | 303 { |
304 const char *txt = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(combo)->entry)); | 304 const char *txt = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(combo)->entry)); |
305 GaimAccount *account; | 305 GaimAccount *account; |
306 | 306 |
307 account = gaim_account_find(txt, -1); | 307 account = gaim_accounts_find(txt, -1); |
308 | 308 |
309 if (account && gaim_account_get_remember_password(account)) { | 309 if (account && gaim_account_get_remember_password(account)) { |
310 gtk_entry_set_text(GTK_ENTRY(pass), account->password); | 310 gtk_entry_set_text(GTK_ENTRY(pass), account->password); |
311 } else { | 311 } else { |
312 gtk_entry_set_text(GTK_ENTRY(pass), ""); | 312 gtk_entry_set_text(GTK_ENTRY(pass), ""); |
546 | 546 |
547 static void set_first_user(char *name) | 547 static void set_first_user(char *name) |
548 { | 548 { |
549 GaimAccount *account; | 549 GaimAccount *account; |
550 | 550 |
551 account = gaim_account_find(name, -1); | 551 account = gaim_accounts_find(name, -1); |
552 | 552 |
553 if (account == NULL) /* new user */ | 553 if (account == NULL) /* new user */ |
554 account = gaim_account_new(name, GAIM_PROTO_DEFAULT); | 554 account = gaim_account_new(name, GAIM_PROTO_DEFAULT); |
555 | 555 |
556 /* Place it as the first user. */ | 556 /* Place it as the first user. */ |