Commit 9f32257a authored by Rex Dieter's avatar Rex Dieter
Browse files

fix build for < libkipi-2

BUG: 307147
parent 92b60776
......@@ -78,6 +78,7 @@
#include <libkipi/plugin.h>
#include <libkipi/pluginloader.h>
#include <libkipi/version.h>
#include <KPluginInfo>
const int max_exponential_value = 50;
......@@ -190,9 +191,13 @@ Kamoso::Kamoso(QWidget* parent)
connect(mTracker, SIGNAL(urlsChanged(KUrl::List)), SLOT(updateThumbnails(KUrl::List)));
QMetaObject::invokeMethod(this, "initialize");
#if (KIPI_VERSION >= 0x020000)
mPluginLoader = new KIPI::PluginLoader();
mPluginLoader->setInterface(new KIPIInterface(this));
mPluginLoader->init();
#else
mPluginLoader = new KIPI::PluginLoader(QStringList(), new KIPIInterface(this), "");
#endif
}
KUrl::List Kamoso::selectedItems()
......
......@@ -26,6 +26,7 @@
#include <KCmdLineArgs>
#include <libkipi/plugin.h>
#include <libkipi/pluginloader.h>
#include <libkipi/version.h>
PluginTester::PluginTester(QObject *parent) : QObject(parent)
{
......@@ -41,9 +42,13 @@ PluginTester::PluginTester(QObject *parent) : QObject(parent)
kurlList.append(KUrl(args->arg(i)));
}
#if (KIPI_VERSION >= 0x020000)
m_pluginLoader = new KIPI::PluginLoader();
m_pluginLoader->setInterface(new FakeKIPIInterface(kurlList));
m_pluginLoader->init();
#else
m_pluginLoader = new KIPI::PluginLoader(QStringList(), new FakeKIPIInterface(kurlList), "");
#endif
bool found = false;
Q_FOREACH(KIPI::PluginLoader::Info *pluginInfo, m_pluginLoader->pluginList()) {
......@@ -60,4 +65,4 @@ PluginTester::PluginTester(QObject *parent) : QObject(parent)
PluginTester::~PluginTester()
{
delete m_action;
}
\ No newline at end of file
}
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