summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2017-04-16 21:30:42 +0200
committerMontel Laurent <[email protected]>2017-04-16 21:30:42 +0200
commit150ea832267a8bd176ad03840887719711e2f09d (patch)
tree1f38c4b0fbf03b0a58425fd04157fd7103be2af6
parent8504eb5018404c9d46aab7aa6f8890e653e3024e (diff)
Convert thebat as plugins
-rw-r--r--src/CMakeLists.txt2
-rw-r--r--src/autodetect/CMakeLists.txt2
-rw-r--r--src/autodetect/thebat/CMakeLists.txt18
-rw-r--r--src/autodetect/thebat/thebatimportdata.cpp4
4 files changed, 25 insertions, 1 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 0f5b831..f5165c3 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -55,7 +55,7 @@ set(libimportwizard_autodetect_SRCS
# autodetect/mailapp/mailappimportdata.cpp
autodetect/pmail/pmailimportdata.cpp
autodetect/pmail/pmailsettings.cpp
- autodetect/thebat/thebatimportdata.cpp
+# autodetect/thebat/thebatimportdata.cpp
# autodetect/balsa/balsaimportdata.cpp
# autodetect/balsa/balsasettings.cpp
# autodetect/balsa/balsaaddressbook.cpp
diff --git a/src/autodetect/CMakeLists.txt b/src/autodetect/CMakeLists.txt
index 0aeaed8..6c43948 100644
--- a/src/autodetect/CMakeLists.txt
+++ b/src/autodetect/CMakeLists.txt
@@ -8,3 +8,5 @@ add_subdirectory(evolutionv1)
add_subdirectory(evolutionv2)
add_subdirectory(evolutionv3)
add_subdirectory(oe)
+add_subdirectory(thebat)
+
diff --git a/src/autodetect/thebat/CMakeLists.txt b/src/autodetect/thebat/CMakeLists.txt
new file mode 100644
index 0000000..44b3f65
--- /dev/null
+++ b/src/autodetect/thebat/CMakeLists.txt
@@ -0,0 +1,18 @@
+set(thebatimporter_SRCS
+ thebatimportdata.cpp
+)
+
+kcoreaddons_add_plugin(thebatimporterplugin JSON thebatimporter.json SOURCES
+ ${thebatimporter_SRCS} INSTALL_NAMESPACE importwizard)
+
+
+target_link_libraries(thebatimporterplugin
+ libimportwizard
+ KF5::XmlGui
+ KF5::I18n
+ KF5::Contacts
+ KF5::MailImporterAkonadi
+ KF5::MailTransport
+ KF5::IdentityManagement
+ KF5::MailCommon
+)
diff --git a/src/autodetect/thebat/thebatimportdata.cpp b/src/autodetect/thebat/thebatimportdata.cpp
index 8ea85a3..a3f5030 100644
--- a/src/autodetect/thebat/thebatimportdata.cpp
+++ b/src/autodetect/thebat/thebatimportdata.cpp
@@ -28,6 +28,8 @@
#include <QDir>
+K_PLUGIN_FACTORY_WITH_JSON(TheBatImporterFactory, "thebatimporter.json", registerPlugin<TheBatImportData>();)
+
TheBatImportData::TheBatImportData(QObject *parent, const QList<QVariant> &)
: AbstractImporter(parent)
{
@@ -74,3 +76,5 @@ AbstractImporter::TypeSupportedOptions TheBatImportData::supportedOption()
options |= AbstractImporter::Mails;
return options;
}
+
+#include "thebatimportdata.moc"