Index: src/summaryview.c =================================================================== RCS file: //claws/src/summaryview.c,v retrieving revision 1.395.2.447 retrieving revision 1.395.2.448 diff -u -r1.395.2.447 -r1.395.2.448 --- src/summaryview.c 27 May 2012 17:31:00 -0000 1.395.2.447 +++ src/summaryview.c 27 Jul 2012 18:50:03 -0000 1.395.2.448 @@ -79,6 +79,7 @@ #include "log.h" #include "edittags.h" #include "manual.h" +#include "manage_window.h" #define SUMMARY_COL_MARK_WIDTH 10 #define SUMMARY_COL_STATUS_WIDTH 13 @@ -4713,6 +4714,9 @@ Xstrdup_a(filename, msginfo->subject, return); subst_for_filename(filename); } + + manage_window_focus_in(summaryview->window, NULL, NULL); + if (filename && !g_utf8_validate(filename, -1, NULL)) { gchar *oldstr = filename; filename = conv_codeset_strdup(filename, Index: src/textview.c =================================================================== RCS file: //claws/src/textview.c,v retrieving revision 1.96.2.243 retrieving revision 1.96.2.244 diff -u -r1.96.2.243 -r1.96.2.244 --- src/textview.c 7 Jul 2012 07:09:30 -0000 1.96.2.243 +++ src/textview.c 27 Jul 2012 18:50:03 -0000 1.96.2.244 @@ -74,6 +74,7 @@ #include "inputdialog.h" #include "timing.h" #include "tags.h" +#include "manage_window.h" static GdkColor quote_colors[3] = { {(gulong)0, (gushort)0, (gushort)0, (gushort)0}, @@ -3060,6 +3061,8 @@ gchar *filepath = NULL; gchar *filedir = NULL; gchar *tmp_filename = NULL; + GtkWidget *window; + if (uri == NULL) return; @@ -3084,6 +3087,14 @@ g_free(filename); + /* Pick correct window to set the file dialog "transient for" */ + if (textview->messageview->window != NULL) + window = textview->messageview->window; + else + window = textview->messageview->mainwin->window; + + manage_window_focus_in(window, NULL, NULL); + filename = filesel_select_file_save(_("Save as"), filepath); if (!filename) { g_free(filepath);