| 352 |
352 |
| 353 msn_slplink_request_ft(slplink, xfer); |
353 msn_slplink_request_ft(slplink, xfer); |
| 354 } |
354 } |
| 355 |
355 |
| 356 static void |
356 static void |
| 357 show_send_file_cb(GaimBlistNode *node, gpointer ignored) |
357 msn_send_file(GaimConnection *gc, const char *who, const char *file) |
| 358 { |
358 { |
| 359 GaimBuddy *buddy; |
|
| 360 GaimConnection *gc; |
|
| 361 MsnSession *session; |
359 MsnSession *session; |
| 362 MsnSlpLink *slplink; |
360 MsnSlpLink *slplink; |
| 363 GaimXfer *xfer; |
361 GaimXfer *xfer; |
| 364 |
362 |
| 365 g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node)); |
363 session = gc->proto_data; |
| 366 |
364 |
| 367 buddy = (GaimBuddy *) node; |
365 xfer = gaim_xfer_new(gc->account, GAIM_XFER_SEND, who); |
| 368 |
366 |
| 369 gc = gaim_account_get_connection(buddy->account); |
367 slplink = msn_session_get_slplink(session, who); |
| 370 session = gc->proto_data; |
|
| 371 |
|
| 372 xfer = gaim_xfer_new(buddy->account, GAIM_XFER_SEND, buddy->name); |
|
| 373 |
|
| 374 slplink = msn_session_get_slplink(session, buddy->name); |
|
| 375 |
368 |
| 376 xfer->data = slplink; |
369 xfer->data = slplink; |
| 377 |
370 |
| 378 gaim_xfer_set_init_fnc(xfer, t_msn_xfer_init); |
371 gaim_xfer_set_init_fnc(xfer, t_msn_xfer_init); |
| 379 |
372 |
| 380 gaim_xfer_request(xfer); |
373 if (file) |
| |
374 gaim_xfer_request_accepted(xfer, file); |
| |
375 else |
| |
376 gaim_xfer_request(xfer); |
| 381 } |
377 } |
| 382 |
378 |
| 383 static void |
379 static void |
| 384 update_buddy_icon_cb(GaimBlistNode *node, gpointer ignored) |
380 update_buddy_icon_cb(GaimBlistNode *node, gpointer ignored) |
| 385 { |
381 { |
| 537 if (g_ascii_strcasecmp(buddy->name, |
533 if (g_ascii_strcasecmp(buddy->name, |
| 538 gaim_account_get_username(buddy->account))) |
534 gaim_account_get_username(buddy->account))) |
| 539 { |
535 { |
| 540 act = gaim_blist_node_action_new(_("Initiate Chat"), |
536 act = gaim_blist_node_action_new(_("Initiate Chat"), |
| 541 initiate_chat_cb, NULL); |
537 initiate_chat_cb, NULL); |
| 542 m = g_list_append(m, act); |
|
| 543 |
|
| 544 act = gaim_blist_node_action_new(_("Send File"), |
|
| 545 show_send_file_cb, NULL); |
|
| 546 |
|
| 547 m = g_list_append(m, act); |
538 m = g_list_append(m, act); |
| 548 |
539 |
| 549 act = gaim_blist_node_action_new(_("Update Buddy Icon"), |
540 act = gaim_blist_node_action_new(_("Update Buddy Icon"), |
| 550 update_buddy_icon_cb, NULL); |
541 update_buddy_icon_cb, NULL); |
| 551 |
542 |