File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -2896,7 +2896,13 @@ void MainSpinWindow::zipProject()
28962896 }
28972897
28982898 // zip folder
2899- zipIt (dTmpPath, dstPath);
2899+ zipIt (dTmpPath, dTmpPath);
2900+ if (dstPath.endsWith (" /" ))
2901+ dstPath = dstPath.left (dstPath.lastIndexOf (" /" ));
2902+ if (dTmpPath.endsWith (" /" ))
2903+ dTmpPath = dTmpPath.left (dTmpPath.lastIndexOf (" /" ));
2904+ QFile::copy (dTmpPath+" .zip" , dstPath+" .zip" );
2905+ QFile::remove (dTmpPath+" .zip" );
29002906
29012907#ifdef ENABLE_KEEP_ZIP_FOLDER
29022908 // and remove folder if save zip folder is not checked
@@ -2977,6 +2983,8 @@ void MainSpinWindow::zipIt(QString dir, QString dst)
29772983 while (inFile.getChar (&c) && outFile.putChar (c))
29782984 ; // yes empty body
29792985
2986+ QApplication::processEvents ();
2987+
29802988 if (outFile.getZipError () != UNZ_OK) {
29812989 QMessageBox::critical (this , tr (" Zip Error" ), QString (" testCreate(): outFile.putChar(): %1" ).arg (outFile.getZipError ()));
29822990 return ;
You can’t perform that action at this time.
0 commit comments