##// END OF EJS Templates
Add the cmake to permits to do cpack to get a standalone installer on Windows....
Add the cmake to permits to do cpack to get a standalone installer on Windows. This one use NSIS and windeployqt. To get the installer please do : cmake, make, cmake cpack. The second cmake is necessary because windeployqt needs the exe file that exists only at the end of the make process

File last commit:

r33:2b201d277e22
r51:a93b95151285
Show More
SqpApplication.cpp
51 lines | 1.5 KiB | text/x-c | CppLexer
/ gui / src / SqpApplication.cpp
#include "SqpApplication.h"
#include <DataSource/DataSourceController.h>
#include <QThread>
Q_LOGGING_CATEGORY(LOG_SqpApplication, "SqpApplication")
class SqpApplication::SqpApplicationPrivate {
public:
SqpApplicationPrivate() : m_DataSourceController{std::make_unique<DataSourceController>()}
{
m_DataSourceController->moveToThread(&m_DataSourceControllerThread);
}
virtual ~SqpApplicationPrivate()
{
qCInfo(LOG_SqpApplication()) << tr("SqpApplicationPrivate destruction");
m_DataSourceControllerThread.quit();
m_DataSourceControllerThread.wait();
}
std::unique_ptr<DataSourceController> m_DataSourceController;
QThread m_DataSourceControllerThread;
};
SqpApplication::SqpApplication(int &argc, char **argv)
: QApplication{argc, argv}, impl{spimpl::make_unique_impl<SqpApplicationPrivate>()}
{
qCInfo(LOG_SqpApplication()) << tr("SqpApplication construction");
connect(&impl->m_DataSourceControllerThread, &QThread::started,
impl->m_DataSourceController.get(), &DataSourceController::initialize);
connect(&impl->m_DataSourceControllerThread, &QThread::finished,
impl->m_DataSourceController.get(), &DataSourceController::finalize);
impl->m_DataSourceControllerThread.start();
}
SqpApplication::~SqpApplication()
{
}
void SqpApplication::initialize()
{
}
DataSourceController &SqpApplication::dataSourceController() const noexcept
{
return *impl->m_DataSourceController;
}