https://bugs.kde.org/show_bug.cgi?id=358208

--- Comment #1 from Thomas Lübking <thomas.luebk...@gmail.com> ---
diff --git a/src/Gui/AttachmentView.cpp b/src/Gui/AttachmentView.cpp
index 4757cf5..39b288a 100644
--- a/src/Gui/AttachmentView.cpp
+++ b/src/Gui/AttachmentView.cpp
@@ -224,8 +224,13 @@ void AttachmentView::slotFileNameRequestedOnOpen(QString
*fileName)

 void AttachmentView::slotFileNameRequested(QString *fileName)
 {
-    QString fileLocation =
QDir(Common::writablePath(Common::LOCATION_DOWNLOAD)).filePath(*fileName);
+    static QDir lastDir =
QDir(Common::writablePath(Common::LOCATION_DOWNLOAD));
+    if (!lastDir.exists())
+        lastDir = QDir(Common::writablePath(Common::LOCATION_DOWNLOAD));
+    QString fileLocation = lastDir.filePath(*fileName);
     *fileName = QFileDialog::getSaveFileName(this, tr("Save Attachment"),
fileLocation, QString(), 0, QFileDialog::HideNameFilterDetails);
+    if (!fileName->isEmpty())
+        lastDir = QFileInfo(*fileName).absoluteDir();
 }

 void AttachmentView::enableDownloadAgain()

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to