Skip to content
Snippets Groups Projects
Commit df270e11 authored by Langella Olivier's avatar Langella Olivier
Browse files

converting qt4 to qt5

parent 296771b4
No related branches found
No related tags found
No related merge requests found
......@@ -13,8 +13,8 @@ SET(xtpcpp_RCCS xtpcpp.qrc)
#FIND_PACKAGE(Boost REQUIRED)
#INCLUDE_DIRECTORIES( ${Boost_INCLUDE_DIRS})
FIND_PACKAGE( Qt4 COMPONENTS QTCORE QTGUI QTSVG QTXML REQUIRED )
QT4_ADD_RESOURCES(xtpcpp_RCC_SRCS ${xtpcpp_RCCS})
FIND_PACKAGE( Qt5 COMPONENTS Core Gui Svg Xml REQUIRED )
QT5_ADD_RESOURCES(xtpcpp_RCC_SRCS ${xtpcpp_RCCS})
FIND_PACKAGE( Odsstream REQUIRED ) #ODSSTREAM_INCLUDE_DIR AND ODSSTREAM_LIBRARY
......@@ -199,9 +199,9 @@ SET(XTPCPP_MOC_HDRS
# this will run uic on .ui files:
QT4_WRAP_UI( GUI_UI_HDRS ${GUI_UIS} )
QT5_WRAP_UI( GUI_UI_HDRS ${GUI_UIS} )
QT4_WRAP_CPP( XTPCPP_MOC_SRCS ${XTPCPP_MOC_HDRS} )
QT5_WRAP_CPP( XTPCPP_MOC_SRCS ${XTPCPP_MOC_HDRS} )
MESSAGE("XTPCPP_SRCS: ${XTPCPP_SRCS}")
......@@ -220,8 +220,8 @@ target_compile_definitions(xtpcpp PUBLIC ${QT_DEFINITIONS})
#COMPILE_DEFINITIONS "${QT_DEFINITIONS}"
#INCLUDE_DIRECTORIES "${QT_INCLUDE_DIR} ${QT_QTCORE_INCLUDE_DIR}"
)
TARGET_LINK_LIBRARIES(xtpcpp ${PAPPSOMSPP_QT4_LIBRARY} ${Pwiz_LIBRARY} ${ODSSTREAM_QT4_LIBRARY}
Qt4::QtGui Qt4::QtXml Qt4::QtSvg)
TARGET_LINK_LIBRARIES(xtpcpp ${PAPPSOMSPP_QT5_LIBRARY} ${Pwiz_LIBRARY} ${ODSSTREAM_QT5_LIBRARY}
Qt5::Gui Qt5::Xml Qt5::Svg)
INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/xtpcpp DESTINATION bin)
......
......@@ -27,9 +27,11 @@
* Olivier Langella <olivier.langella@u-psud.fr> - initial API and implementation
******************************************************************************/
#include "tandecondorprocess.h"
#include "tandemcondorprocess.h"
#include <QDebug>
#include <pappsomspp/pappsoexception.h>
TandeCondorProcess(WorkMonitorInterface * p_monitor, const TandemRunBatch & tandem_run_batch) : TandemBatchProcess(p_monitor, tandem_run_batch) {
TandemCondorProcess::TandemCondorProcess(WorkMonitorInterface * p_monitor, const TandemRunBatch & tandem_run_batch) : TandemBatchProcess(p_monitor, tandem_run_batch) {
/*
Universe = vanilla
notification = Error
......@@ -46,7 +48,7 @@ TandeCondorProcess(WorkMonitorInterface * p_monitor, const TandemRunBatch & tand
*/
}
void TandeCondorProcess::run() {
void TandemCondorProcess::run() {
qDebug() << "TandeCondorProcess::run begin " << _tandem_run_batch._preset_file;
_preset_file = _tandem_run_batch._preset_file;
......
......@@ -27,15 +27,15 @@
* Olivier Langella <olivier.langella@u-psud.fr> - initial API and implementation
******************************************************************************/
#ifndef TANDECONDORPROCESS_H
#define TANDECONDORPROCESS_H
#ifndef TANDEMCONDORPROCESS_H
#define TANDEMCONDORPROCESS_H
#include "tandembatchprocess.h"
class TandeCondorProcess: public TandemBatchProcess
class TandemCondorProcess: public TandemBatchProcess
{
public:
TandeCondorProcess(WorkMonitorInterface * p_monitor, const TandemRunBatch & tandem_run_batch);
TandemCondorProcess(WorkMonitorInterface * p_monitor, const TandemRunBatch & tandem_run_batch);
virtual void run();
......
......@@ -80,6 +80,9 @@ MainWindow::MainWindow(QWidget *parent):
#if QT_VERSION >= 0x050000
// Qt5 code
connect(_p_tandem_run_dialog, &TandemRunDialog::accepted, this, &MainWindow::doAcceptedTandemRunDialog);
connect(_p_load_results_dialog, &LoadResultsDialog::accepted, this,&MainWindow::doAcceptedLoadResultDialog);
connect(_p_export_spreadsheet_dialog, &ExportSpreadsheetDialog::accepted, this,&MainWindow::doAcceptedExportSpreadsheetDialog);
/*
connect(&workerThread, &QThread::finished, worker, &QObject::deleteLater);
connect(this, &PtSpectrumViewer::operateMsDataFile, worker, &PwizLoaderThread::doMsDataFileLoad);
......@@ -92,11 +95,6 @@ MainWindow::MainWindow(QWidget *parent):
connect(_p_load_results_dialog, SIGNAL(accepted()), this,SLOT(doAcceptedLoadResultDialog()));
connect(_p_export_spreadsheet_dialog, SIGNAL(accepted()), this,SLOT(doAcceptedExportSpreadsheetDialog()));
/*
connect(&workerThread, SIGNAL(finished()), worker, SLOT(deleteLater()));
connect(this, SIGNAL(operateMsDataFile(QString)), worker,SLOT(doMsDataFileLoad(QString)));
connect(worker, SIGNAL(msDataReady(pwiz::msdata::MSDataFile *)), this, SLOT(handleMsDataFile(pwiz::msdata::MSDataFile *)));
*/
#endif
}
......
......@@ -35,7 +35,7 @@
#include <QMessageBox>
#include <pappsomspp/pappsoexception.h>
Q_DECLARE_METATYPE(QFileInfo)
//Q_DECLARE_METATYPE(QFileInfo)
TandemRunDialog::TandemRunDialog(QWidget * parent):
QDialog(parent),
......
......@@ -47,6 +47,10 @@ WorkerThread::WorkerThread(MainWindow * p_main_window)
#if QT_VERSION >= 0x050000
// Qt5 code
//worker message
connect(_p_work_monitor, static_cast<void (WorkMonitor::*)(QString)>(&WorkMonitor::workerMessage), p_main_window,static_cast<void (MainWindow::*)(QString)>(&MainWindow::doDisplayLoadingMessage));
connect(_p_work_monitor, static_cast<void (WorkMonitor::*)(QString,int)>(&WorkMonitor::workerMessage), p_main_window,static_cast<void (MainWindow::*)(QString,int)>(&MainWindow::doDisplayLoadingMessage));
connect(_p_work_monitor, &WorkMonitor::workerAppendText, p_main_window,&MainWindow::doWorkerAppendText);
/*
connect(&workerThread, &QThread::finished, worker, &QObject::deleteLater);
connect(this, &PtSpectrumViewer::operateMsDataFile, worker, &PwizLoaderThread::doMsDataFileLoad);
......@@ -78,11 +82,6 @@ WorkerThread::WorkerThread(MainWindow * p_main_window)
connect(p_main_window, SIGNAL(operateWritingOdsFile(QString, ProjectSp)), this,SLOT(doWritingOdsFile(QString, ProjectSp)));
connect(this, SIGNAL(operationFailed(QString)), p_main_window,SLOT(doOperationFailed(QString)));
connect(this, SIGNAL(operationFinished()), p_main_window,SLOT(doOperationFinished()));
/*
connect(&workerThread, SIGNAL(finished()), worker, SLOT(deleteLater()));
connect(this, SIGNAL(operateMsDataFile(QString)), worker,SLOT(doMsDataFileLoad(QString)));
connect(worker, SIGNAL(msDataReady(pwiz::msdata::MSDataFile *)), this, SLOT(handleMsDataFile(pwiz::msdata::MSDataFile *)));
*/
#endif
qDebug() << "WorkerThread::WorkerThread end MainWindow";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment