diff --git a/RsyncUI.pro b/RsyncUI.pro index 9096888..4936592 100644 --- a/RsyncUI.pro +++ b/RsyncUI.pro @@ -24,6 +24,7 @@ SOURCES += \ tools.cpp HEADERS += \ + version.h\ downloadfile.h \ mainwindow.h \ password.h \ diff --git a/RsyncUI.pro.user b/RsyncUI.pro.user index c5fa078..f367f34 100644 --- a/RsyncUI.pro.user +++ b/RsyncUI.pro.user @@ -1,6 +1,6 @@ - + EnvironmentId @@ -40,7 +40,7 @@ false true false - 1 + 0 true true 0 @@ -52,7 +52,7 @@ true true *.md, *.MD, Makefile - true + false true true @@ -71,6 +71,9 @@ 0 true + + true + Builtin.Questionable true true @@ -81,61 +84,24 @@ true + + true + ProjectExplorer.Project.Target.0 Desktop - Desktop - Desktop - {893f9ca6-0efa-4c08-a4a6-5a818f60a8a0} + Qt 5.15.7 (qt5) + Qt 5.15.7 (qt5) + {a8a6d767-5e05-45c7-b70b-532f99112b6a} 0 0 0 - 0 - /home/daniel/develop/RsyncUI6/../build-RsyncUI6-Desktop-Debug - /home/daniel/develop/build-RsyncUI6-Desktop-Debug - - - true - QtProjectManager.QMakeBuildStep - false - - - - true - Qt4ProjectManager.MakeStep - - 2 - Build - Build - ProjectExplorer.BuildSteps.Build - - - - true - Qt4ProjectManager.MakeStep - clean - - 1 - Clean - Clean - ProjectExplorer.BuildSteps.Clean - - 2 - false - - false - - Debug - Qt4ProjectManager.Qt4BuildConfiguration - 2 - - - /home/daniel/develop/RsyncUI6/../build-RsyncUI6-Desktop-Release - /home/daniel/develop/build-RsyncUI6-Desktop-Release + /home/daniel/develop/RsyncUI + /home/daniel/develop/RsyncUI true @@ -171,51 +137,8 @@ Release Qt4ProjectManager.Qt4BuildConfiguration 0 - 0 - - 0 - /home/daniel/develop/RsyncUI6/../build-RsyncUI6-Desktop-Profile - /home/daniel/develop/build-RsyncUI6-Desktop-Profile - - - true - QtProjectManager.QMakeBuildStep - false - - - - true - Qt4ProjectManager.MakeStep - - 2 - Build - Build - ProjectExplorer.BuildSteps.Build - - - - true - Qt4ProjectManager.MakeStep - clean - - 1 - Clean - Clean - ProjectExplorer.BuildSteps.Clean - - 2 - false - - false - - Profile - Qt4ProjectManager.Qt4BuildConfiguration - 0 - 0 - 0 - - 3 + 1 0 @@ -233,34 +156,18 @@ true true true - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - 2 - Qt4ProjectManager.Qt4RunConfiguration:/home/daniel/develop/RsyncUI6/RsyncUI6.pro - /home/daniel/develop/RsyncUI6/RsyncUI6.pro + RsyncUI + Qt4ProjectManager.Qt4RunConfiguration:/home/daniel/develop/RsyncUI/RsyncUI.pro + /home/daniel/develop/RsyncUI/RsyncUI.pro false true true false true - /home/daniel/develop/build-RsyncUI6-Desktop-Debug + /home/daniel/develop/RsyncUI 1 diff --git a/downloadfile.cpp b/downloadfile.cpp index 732eb54..f38b08a 100644 --- a/downloadfile.cpp +++ b/downloadfile.cpp @@ -67,7 +67,6 @@ void MainWindow::download() //connect(this->downloading.process, SIGNAL(errorOccurred(QProcess::ProcessError error)), this, SLOT(downloadProcessError(QProcess::ProcessError error))); //connect(this->downloading.process, SIGNAL(readyReadStandardError()), this, SLOT(downloadProcessStderr())); connect(this->downloading.process, SIGNAL(readyReadStandardOutput()), this, SLOT(readRsyncOutput())); - this->downloading.process->start(cmd, param); } diff --git a/mainwindow.cpp b/mainwindow.cpp index 10bcb42..be05e17 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -1,6 +1,7 @@ #include "mainwindow.h" #include #include +#include "version.h" using namespace std; @@ -50,8 +51,9 @@ MainWindow::MainWindow(QWidget *parent) AboutW.setupUi(&aboutDialog); // text of About + this->about.version = version; QString aboutText = tr("

Client for rsync server

") + - "" + tr("Version") + ": " + this->about.version + "
" + + "" + tr("Version") + ": " + version + "
" + "" + tr("Licence") + ": " + this->about.licence + "
" + "" + tr("Author") + ": " + this->about.author + "
" + "" + tr("EMail") + ": " + this->about.email + "
" + @@ -1077,6 +1079,7 @@ void MainWindow::downloadFinished(int exitCode, QProcess::ExitStatus exitStatus) pos = path.lastIndexOf(" => "); this->downloading.server = path.midRef(pos+4).toString(); path.resize(pos); + this->downloading.port = this->settings.value("connexion/server/" + this->downloading.server).toInt(); this->downloading.path = path; //getUserPassword(true); diff --git a/mainwindow.h b/mainwindow.h index 967c129..eff508f 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -88,7 +88,7 @@ class Downloading class About { public: - QString version = "2.11.5"; + QString version; QString author = "Daniel TARTAVEL-JEANNOT"; QString licence = "GPL_V3"; QString description; diff --git a/password.cpp b/password.cpp index faa4831..beb6cf5 100644 --- a/password.cpp +++ b/password.cpp @@ -1,4 +1,4 @@ -#include "mainwindow.h" +//#include "mainwindow.h" #include "password.h" #include #include diff --git a/tools.cpp b/tools.cpp index ad97286..d988e0a 100644 --- a/tools.cpp +++ b/tools.cpp @@ -50,6 +50,7 @@ bool testRsyncReturn(MainWindow * w, QProcess * myProcess) { if (myProcess->exitStatus() != 0 and w->stopDlAsked != true) { + cout << "rsync error: " << myProcess->error() << " : " << myProcess->errorString().toStdString() << endl; QMessageBox::warning( w, a.applicationName(), diff --git a/tools.h b/tools.h index 2f6cf89..a8e6317 100644 --- a/tools.h +++ b/tools.h @@ -1,7 +1,7 @@ #ifndef TOOLS_H #define TOOLS_H -#include "mainwindow.h" +//#include "mainwindow.h" #include #include #include diff --git a/version.h b/version.h new file mode 100644 index 0000000..c4a469f --- /dev/null +++ b/version.h @@ -0,0 +1,8 @@ +#ifndef VERSION_H +#define VERSION_H + +#include + +QString version = "2.11.5"; + +#endif // VERSION_H