Mercurial > pidgin
diff src/gtkconv.c @ 13147:21ee457d479c
[gaim-migrate @ 15510]
Part of SF Patch #1413778 from Sadrul
"It also makes the gtkconv the handle for the notify/
request dialogs, which I think makes more sense."
committer: Tailor Script <tailor@pidgin.im>
author | Richard Laager <rlaager@wiktel.com> |
---|---|
date | Tue, 07 Feb 2006 02:33:17 +0000 |
parents | 05ef36447131 |
children | f09c6e8df82c |
line wrap: on
line diff
--- a/src/gtkconv.c Tue Feb 07 02:22:36 2006 +0000 +++ b/src/gtkconv.c Tue Feb 07 02:33:17 2006 +0000 @@ -740,7 +740,7 @@ if (strcmp(convprotocol, gaim_account_get_protocol_id(buddy->account))) { - gaim_notify_error(NULL, NULL, + gaim_notify_error(GAIM_GTK_CONVERSATION(info->conv), NULL, _("That buddy is not on the same protocol as this " "chat."), NULL); } @@ -760,13 +760,13 @@ { if (account == NULL) { - gaim_notify_error(NULL, NULL, + gaim_notify_error(GAIM_GTK_CONVERSATION(info->conv), NULL, _("You are not currently signed on with an account that " "can invite that buddy."), NULL); } else if (strcmp(convprotocol, gaim_account_get_protocol_id(account))) { - gaim_notify_error(NULL, NULL, + gaim_notify_error(GAIM_GTK_CONVERSATION(info->conv), NULL, _("That buddy is not on the same protocol as this " "chat."), NULL); } @@ -942,7 +942,7 @@ gchar *text; if ((fp = g_fopen(filename, "w+")) == NULL) { - gaim_notify_error(conv, NULL, _("Unable to open file."), NULL); + gaim_notify_error(GAIM_GTK_CONVERSATION(conv), NULL, _("Unable to open file."), NULL); return; } @@ -972,7 +972,8 @@ buf = g_strdup_printf("%s.html", gaim_normalize(conv->account, conv->name)); - gaim_request_file(conv, _("Save Conversation"), gaim_escape_filename(buf), + gaim_request_file(GAIM_GTK_CONVERSATION(conv), _("Save Conversation"), + gaim_escape_filename(buf), TRUE, G_CALLBACK(savelog_writefile_cb), NULL, conv); g_free(buf); @@ -2395,7 +2396,7 @@ size_t len; if ((fp = g_fopen(filename, "wb")) == NULL) { - gaim_notify_error(conv, NULL, _("Unable to open file."), NULL); + gaim_notify_error(gtkconv, NULL, _("Unable to open file."), NULL); return; } @@ -2403,7 +2404,7 @@ data = gaim_buddy_icon_get_data(icon, &len); if ((len <= 0) || (data == NULL)) { - gaim_notify_error(conv, NULL, _("Unable to save icon file to disk."), NULL); + gaim_notify_error(gtkconv, NULL, _("Unable to save icon file to disk."), NULL); return; } @@ -2426,7 +2427,7 @@ buf = g_strdup_printf("%s.%s", gaim_normalize(conv->account, conv->name), ext); - gaim_request_file(conv, _("Save Icon"), buf, TRUE, + gaim_request_file(gtkconv, _("Save Icon"), buf, TRUE, G_CALLBACK(saveicon_writefile_cb), NULL, gtkconv); g_free(buf); @@ -4198,7 +4199,7 @@ { if (account == NULL) { - gaim_notify_error(NULL, NULL, + gaim_notify_error(win, NULL, _("You are not currently signed on with an account that " "can add that buddy."), NULL); } @@ -4447,7 +4448,8 @@ gaim_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv); /* If the "Save Conversation" or "Save Icon" dialogs are open then close them */ - gaim_request_close_with_handle(conv); + gaim_request_close_with_handle(gtkconv); + gaim_notify_close_with_handle(gtkconv); gtk_widget_destroy(gtkconv->tab_cont); g_object_unref(gtkconv->tab_cont); @@ -7431,6 +7433,8 @@ g_object_unref(G_OBJECT(win->menu.item_factory)); + gaim_notify_close_with_handle(win); + g_free(win); }