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

- Remove QT4 ifdefs from interfaces

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