Commit c1696b74 authored by Jan Möbius's avatar Jan Möbius

- Remove QT4 ifdefs from interfaces

refs #141
parent e874e5b7
......@@ -67,11 +67,6 @@
#include <ACG/QtWidgets/QtFileDialog.hh>
// -------------------- Qt
#if QT_VERSION >= 0x050000
#else
#undef QT_NO_OPENGL
#include <QGLFormat>
#endif
#include "OpenFlipper/BasePlugin/KeyInterface.hh"
#include "OpenFlipper/BasePlugin/MouseInterface.hh"
......
......@@ -1250,10 +1250,8 @@ private slots:
signals:
void genericMetadataDeserialized(QString key, QString value);
void objectMetadataDeserialized(QString object_name, QString value);
#if QT_VERSION >= 0x050000
void objectMetadataDeserializedJson(
QString object_name, QJsonDocument value);
#endif
private slots:
void slotMetadataDeserialized( const QVector<QPair<QString, QString> > &data);
......
......@@ -533,7 +533,6 @@ void Core::slotMetadataDeserialized(
const QStringRef value = obj_metadata.midRef(cursor, next - cursor);
emit objectMetadataDeserialized(current_object_name, value.toString());
#if QT_VERSION >= 0x050000
QJsonParseError json_error;
QJsonDocument json_doc =
QJsonDocument::fromJson(value.toUtf8(), &json_error);
......@@ -541,7 +540,6 @@ void Core::slotMetadataDeserialized(
emit objectMetadataDeserializedJson(
current_object_name, json_doc);
}
#endif
cursor = next + re_end.matchedLength();
state = STATE_SEARCH_BEGIN;
break;
......
......@@ -62,8 +62,6 @@
// -------------------- mview
#include "Core.hh"
#if QT_VERSION >= 0x050000
#endif
#include "OpenFlipper/BasePlugin/AboutInfoInterface.hh"
#include "OpenFlipper/BasePlugin/KeyInterface.hh"
......@@ -316,7 +314,6 @@ void Core::loadPlugins()
// Prepend the additional Plugins to the plugin list
pluginlist = additionalPlugins << pluginlist;
#if QT_VERSION >= 0x050000
/*
* Remove static plugins from dynamically loaded list.
*/
......@@ -334,7 +331,6 @@ void Core::loadPlugins()
}
}
}
#endif
/*
* Note: This call is not necessary, anymore. Initialization order
......@@ -430,7 +426,6 @@ void Core::loadPlugins()
delete *it;
}
#if QT_VERSION >= 0x050000
/*
* Initialize static plugins.
*/
......@@ -448,7 +443,6 @@ void Core::loadPlugins()
licenseTexts += pluginLicenseText;
}
}
#endif
emit log(LOGINFO, tr("Total time needed to load plugins was %1 ms.").arg(time.elapsed()));
......@@ -2309,12 +2303,10 @@ void Core::loadPlugin(const QString& _filename,const bool _silent, QString& _lic
connect(this, SIGNAL(objectMetadataDeserialized(QString, QString)),
plugin, SLOT(slotObjectMetadataDeserialized(QString, QString)));
}
#if QT_VERSION >= 0x050000
if (checkSlot(plugin, "slotObjectMetadataDeserializedJson(QString,QJsonDocument)")) {
connect(this, SIGNAL(objectMetadataDeserializedJson(QString, QJsonDocument)),
plugin, SLOT(slotObjectMetadataDeserializedJson(QString, QJsonDocument)));
}
#endif
if (checkSignal(plugin, "metadataDeserialized(QVector<QPair<QString,QString> >)")) {
connect(plugin, SIGNAL(metadataDeserialized(QVector<QPair<QString, QString> >)),
this, SLOT(slotMetadataDeserialized(QVector<QPair<QString, QString> >)));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment