File renamepreview.patch of Package digikam

--- digikam/utilities/cameragui/cameracontroller.cpp	2008/07/17 11:28:19	1.1
+++ digikam/utilities/cameragui/cameracontroller.cpp	2008/07/17 11:29:19
@@ -54,6 +54,7 @@
 #include <kmessagebox.h>
 #include <kio/renamedlg.h>
 #include <kstandarddirs.h>
+#include <ktempfile.h>
 
 // Local includes.
 
@@ -935,13 +936,18 @@
                         break;
                     }
 
+                    KTempFile tmp;
+                    tmp.close();
+                    d->camera->downloadItem(folder, file, tmp.name());
+
                     KIO::RenameDlg dlg(d->parent, i18n("Rename File"),
-                                       folder + QString("/") + file, dest,
+                                       tmp.name(), dest,
                                        KIO::RenameDlg_Mode(KIO::M_MULTI | KIO::M_OVERWRITE | KIO::M_SKIP));
 
                     int result = dlg.exec();
                     dest       = dlg.newDestURL().path();
                     info       = QFileInfo(dest);
+                    tmp.unlink();
 
                     switch (result)
                     {
openSUSE Build Service is sponsored by