Add switch for KF5 (QT6) and Mod Cmake

if we want to test QET on QT6, KF5 must be removed from the code,
this switch is for that,

this is for testing only
This commit is contained in:
Simon De Backer
2020-12-16 23:06:08 +01:00
parent 13db08ad56
commit cb37c1c2fe
15 changed files with 135 additions and 116 deletions

View File

@@ -27,8 +27,10 @@
#include "properties/xrefproperties.h"
#include "titleblock/templatescollection.h"
#include "titleblockproperties.h"
#include <KAutoSaveFile>
#ifdef BUILD_WITHOUT_KF5
#else
# include <KAutoSaveFile>
#endif
#include <QHash>
class Diagram;
@@ -40,7 +42,10 @@ class NumerotationContext;
class QUndoStack;
class XmlElementCollection;
class QTimer;
#ifdef BUILD_WITHOUT_KF5
#else
class KAutoSaveFile;
#endif
/**
This class represents a QET project. Typically saved as a .qet file, it
@@ -68,7 +73,10 @@ class QETProject : public QObject
public:
QETProject (QObject *parent = nullptr);
QETProject (const QString &path, QObject * = nullptr);
#ifdef BUILD_WITHOUT_KF5
#else
QETProject (KAutoSaveFile *backup, QObject *parent=nullptr);
#endif
~QETProject() override;
private:
@@ -267,7 +275,10 @@ class QETProject : public QObject
bool m_freeze_new_conductors = false;
QTimer m_save_backup_timer,
m_autosave_timer;
#ifdef BUILD_WITHOUT_KF5
#else
KAutoSaveFile m_backup_file;
#endif
QUuid m_uuid = QUuid::createUuid();
projectDataBase m_data_base;
};