Mercurial > pidgin.yaz
comparison src/gtkconv.c @ 7650:6db061321ec4
[gaim-migrate @ 8293]
I completely reverted the dnd sendfile stuff. I thought most of it was
pretty decent. The parts for adding the sendfile option to the conv
window looked good to me. I can't comment on the dnd stuff.
In oscar.c, I didn't see a need to duplicate the oscar_ask_sendfile
function. I also don't think the right click->send file option
should have been removed... but that's just one man's opinion.
Sean, could you please talk to Chip and/or the author of this patch
and work towards making it acceptable by you?
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Fri, 28 Nov 2003 19:30:45 +0000 |
parents | 1ffe44bb2573 |
children | cf6a7939af78 |
comparison
equal
deleted
inserted
replaced
7649:7762b3bdfe09 | 7650:6db061321ec4 |
---|---|
879 | 879 |
880 invite_cb(NULL, conv); | 880 invite_cb(NULL, conv); |
881 } | 881 } |
882 | 882 |
883 static void | 883 static void |
884 menu_sendfile_cb(gpointer data, guint action, GtkWidget *widget) | |
885 { | |
886 GaimConvWindow *win = (GaimConvWindow *)data; | |
887 GaimConversation *conv; | |
888 GaimConnection *gc; | |
889 | |
890 conv = gaim_conv_window_get_active_conversation(win); | |
891 | |
892 gc = gaim_conversation_get_gc(conv); | |
893 | |
894 gaim_prpl_ask_send_file (gc, gaim_conversation_get_name (conv)); | |
895 } | |
896 | |
897 static void | |
898 menu_warn_cb(gpointer data, guint action, GtkWidget *widget) | 884 menu_warn_cb(gpointer data, guint action, GtkWidget *widget) |
899 { | 885 { |
900 GaimConvWindow *win = (GaimConvWindow *)data; | 886 GaimConvWindow *win = (GaimConvWindow *)data; |
901 GaimConversation *conv; | 887 GaimConversation *conv; |
902 | 888 |
2091 if (gc != NULL) { | 2077 if (gc != NULL) { |
2092 gtk_widget_set_sensitive(gtkwin->menu.insert_link, TRUE); | 2078 gtk_widget_set_sensitive(gtkwin->menu.insert_link, TRUE); |
2093 prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl); | 2079 prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl); |
2094 } | 2080 } |
2095 | 2081 |
2096 | |
2097 if (gaim_prpl_has_send_file (gc, gaim_conversation_get_name(conv))) { | |
2098 gtk_widget_show(gtkwin->menu.sendfile); | |
2099 gtk_widget_set_sensitive(gtkwin->menu.sendfile, TRUE); | |
2100 } else { | |
2101 gtk_widget_hide(gtkwin->menu.sendfile); | |
2102 gtk_widget_set_sensitive(gtkwin->menu.sendfile, FALSE); | |
2103 } | |
2104 | |
2105 | |
2106 if (gaim_prpl_has_send_file (gc, gaim_conversation_get_name(conv))) { | |
2107 gtk_widget_show(gtkwin->menu.sendfile); | |
2108 gtk_widget_set_sensitive(gtkwin->menu.sendfile, TRUE); | |
2109 } else { | |
2110 gtk_widget_hide(gtkwin->menu.sendfile); | |
2111 gtk_widget_set_sensitive(gtkwin->menu.sendfile, FALSE); | |
2112 } | |
2113 | |
2114 /* Update the menubar */ | 2082 /* Update the menubar */ |
2115 if (gaim_conversation_get_type(conv) == GAIM_CONV_IM) { | 2083 if (gaim_conversation_get_type(conv) == GAIM_CONV_IM) { |
2116 gtk_widget_show(gtkwin->menu.view_log); | 2084 gtk_widget_show(gtkwin->menu.view_log); |
2117 | 2085 |
2118 if (gc && prpl_info->options & OPT_PROTO_IM_IMAGE) { | 2086 if (gc && prpl_info->options & OPT_PROTO_IM_IMAGE) { |
2967 { N_("/Conversation/_Get Info..."), NULL, menu_get_info_cb, 0, | 2935 { N_("/Conversation/_Get Info..."), NULL, menu_get_info_cb, 0, |
2968 "<StockItem>", GAIM_STOCK_INFO }, | 2936 "<StockItem>", GAIM_STOCK_INFO }, |
2969 { N_("/Conversation/In_vite..."), NULL, menu_invite_cb, 0, | 2937 { N_("/Conversation/In_vite..."), NULL, menu_invite_cb, 0, |
2970 "<StockItem>", GAIM_STOCK_INVITE }, | 2938 "<StockItem>", GAIM_STOCK_INVITE }, |
2971 | 2939 |
2972 { N_("/Conversation/Send _File..."), NULL, menu_sendfile_cb, 0, | |
2973 "<StockItem>", GAIM_STOCK_INVITE }, | |
2974 | |
2975 { N_("/Conversation/Send _File..."), NULL, menu_sendfile_cb, 0, | |
2976 "<StockItem>", GAIM_STOCK_INVITE }, | |
2977 | |
2978 { "/Conversation/sep2", NULL, NULL, 0, "<Separator>" }, | 2940 { "/Conversation/sep2", NULL, NULL, 0, "<Separator>" }, |
2979 | 2941 |
2980 { N_("/Conversation/Insert _URL..."), NULL, menu_insert_link_cb, 0, | 2942 { N_("/Conversation/Insert _URL..."), NULL, menu_insert_link_cb, 0, |
2981 "<StockItem>", GAIM_STOCK_LINK }, | 2943 "<StockItem>", GAIM_STOCK_LINK }, |
2982 { N_("/Conversation/Insert _Image..."), NULL, menu_insert_image_cb, 0, | 2944 { N_("/Conversation/Insert _Image..."), NULL, menu_insert_image_cb, 0, |
3060 N_("/Conversation/Get Info...")); | 3022 N_("/Conversation/Get Info...")); |
3061 | 3023 |
3062 gtkwin->menu.invite = | 3024 gtkwin->menu.invite = |
3063 gtk_item_factory_get_widget(gtkwin->menu.item_factory, | 3025 gtk_item_factory_get_widget(gtkwin->menu.item_factory, |
3064 N_("/Conversation/Invite...")); | 3026 N_("/Conversation/Invite...")); |
3065 | |
3066 gtkwin->menu.sendfile = | |
3067 gtk_item_factory_get_widget(gtkwin->menu.item_factory, | |
3068 N_("/Conversation/Send File...")); | |
3069 | |
3070 gtkwin->menu.sendfile = | |
3071 gtk_item_factory_get_widget(gtkwin->menu.item_factory, | |
3072 N_("/Conversation/Send File...")); | |
3073 | 3027 |
3074 /* --- */ | 3028 /* --- */ |
3075 | 3029 |
3076 gtkwin->menu.insert_link = | 3030 gtkwin->menu.insert_link = |
3077 gtk_item_factory_get_widget(gtkwin->menu.item_factory, | 3031 gtk_item_factory_get_widget(gtkwin->menu.item_factory, |