| 95 PurpleBlistNode *node = NULL; |
95 PurpleBlistNode *node = NULL; |
| 96 |
96 |
| 97 if (PURPLE_IS_IM_CONVERSATION(conv)) { |
97 if (PURPLE_IS_IM_CONVERSATION(conv)) { |
| 98 node = (PurpleBlistNode*)find_buddy_for_conversation(conv); |
98 node = (PurpleBlistNode*)find_buddy_for_conversation(conv); |
| 99 node = node ? purple_blist_node_get_parent(node) : NULL; |
99 node = node ? purple_blist_node_get_parent(node) : NULL; |
| 100 } else { |
100 } else if (PURPLE_IS_CHAT_CONVERSATION(conv)) { |
| 101 node = (PurpleBlistNode*)find_chat_for_conversation(conv); |
101 node = (PurpleBlistNode*)find_chat_for_conversation(conv); |
| 102 } |
102 } |
| 103 |
103 |
| 104 return node; |
104 return node; |
| 105 } |
105 } |
| 521 fc = ggc; |
521 fc = ggc; |
| 522 conv = fc->active_conv; |
522 conv = fc->active_conv; |
| 523 |
523 |
| 524 if (PURPLE_IS_IM_CONVERSATION(conv)) |
524 if (PURPLE_IS_IM_CONVERSATION(conv)) |
| 525 type = PURPLE_LOG_IM; |
525 type = PURPLE_LOG_IM; |
| |
526 else if (PURPLE_IS_CHAT_CONVERSATION(conv)) |
| |
527 type = PURPLE_LOG_CHAT; |
| 526 else |
528 else |
| 527 type = PURPLE_LOG_CHAT; |
529 return; |
| 528 |
530 |
| 529 name = purple_conversation_get_name(conv); |
531 name = purple_conversation_get_name(conv); |
| 530 account = purple_conversation_get_account(conv); |
532 account = purple_conversation_get_account(conv); |
| 531 |
533 |
| 532 buddies = purple_blist_find_buddies(account, name); |
534 buddies = purple_blist_find_buddies(account, name); |
| 656 gnt_menu_add_item(GNT_MENU(sub), item); |
658 gnt_menu_add_item(GNT_MENU(sub), item); |
| 657 gnt_menuitem_set_callback(item, send_file_cb, ggc); |
659 gnt_menuitem_set_callback(item, send_file_cb, ggc); |
| 658 } |
660 } |
| 659 |
661 |
| 660 generate_send_to_menu(ggc); |
662 generate_send_to_menu(ggc); |
| 661 } else { |
663 } else if (PURPLE_IS_CHAT_CONVERSATION(ggc->active_conv)) { |
| 662 item = gnt_menuitem_new(_("Invite...")); |
664 item = gnt_menuitem_new(_("Invite...")); |
| 663 gnt_menu_add_item(GNT_MENU(sub), item); |
665 gnt_menu_add_item(GNT_MENU(sub), item); |
| 664 gnt_menuitem_set_callback(item, invite_cb, ggc); |
666 gnt_menuitem_set_callback(item, invite_cb, ggc); |
| 665 } |
667 } |
| 666 |
668 |
| 808 ggc->window = gnt_vwindow_new(FALSE); |
810 ggc->window = gnt_vwindow_new(FALSE); |
| 809 gnt_box_set_title(GNT_BOX(ggc->window), title); |
811 gnt_box_set_title(GNT_BOX(ggc->window), title); |
| 810 gnt_box_set_toplevel(GNT_BOX(ggc->window), TRUE); |
812 gnt_box_set_toplevel(GNT_BOX(ggc->window), TRUE); |
| 811 gnt_box_set_pad(GNT_BOX(ggc->window), 0); |
813 gnt_box_set_pad(GNT_BOX(ggc->window), 0); |
| 812 |
814 |
| 813 gnt_widget_set_name(ggc->window, |
815 if (PURPLE_IS_IM_CONVERSATION(conv)) |
| 814 PURPLE_IS_IM_CONVERSATION(conv) ? "conversation-window-im" : "conversation-window-chat"); |
816 gnt_widget_set_name(ggc->window, "conversation-window-im"); |
| |
817 else if (PURPLE_IS_CHAT_CONVERSATION(conv)) |
| |
818 gnt_widget_set_name(ggc->window, "conversation-window-chat"); |
| |
819 else |
| |
820 gnt_widget_set_name(ggc->window, "conversation-window-other"); |
| 815 |
821 |
| 816 ggc->tv = gnt_text_view_new(); |
822 ggc->tv = gnt_text_view_new(); |
| 817 gnt_widget_set_name(ggc->tv, "conversation-window-textview"); |
823 gnt_widget_set_name(ggc->tv, "conversation-window-textview"); |
| 818 gnt_widget_set_size(ggc->tv, purple_prefs_get_int(PREF_ROOT "/size/width"), |
824 gnt_widget_set_size(ggc->tv, purple_prefs_get_int(PREF_ROOT "/size/width"), |
| 819 purple_prefs_get_int(PREF_ROOT "/size/height")); |
825 purple_prefs_get_int(PREF_ROOT "/size/height")); |