Use pluginLoader as a dedicated static object.

This commit is contained in:
Gerhard Hoffmann 2023-09-10 16:50:19 +02:00
parent 103b3f3f9c
commit 38e79f0354

View File

@ -7,6 +7,7 @@
#include <QDir>
#include <QByteArray>
#include <QProcess>
#include <QPluginLoader>
#include "plugins/interfaces.h"
@ -32,11 +33,14 @@ class Update : public QObject {
bool m_maintenanceMode;
bool m_dryRun;
static QPluginLoader pluginLoader;
public:
enum class DownloadResult {OK, ERROR, TIMEOUT, NOP};
enum class FileTypeJson {CONFIG=1, DEVICE=2, CASH=3, SERIAL=4, TIME=5, PRINTER=6};
static hwinf *loadDCPlugin(QDir const &plugInDir, QString const &fn);
static bool unloadDCPlugin();
static QStringList split(QString line, QChar sep = ',');