Commit 2971f5dd authored by Laurent Montel's avatar Laurent Montel 😁

not dependency against akonadi

parent 2ba6eeed
......@@ -59,6 +59,7 @@ set(kdepim_multiplyingline_LIB_SRCS
set(kdepim_addressline_LIB_SRCS
addressline/recentaddress/recentaddresswidget.cpp
addressline/recentaddress/recentaddresses.cpp
addressline/addresslineedit/addresseelineeditutil.cpp
)
......@@ -187,6 +188,15 @@ ecm_generate_headers(libkdepim_Camelcaserecentaddress_HEADERS
RELATIVE addressline/recentaddress/
)
ecm_generate_headers(libkdepim_Camelcaseaddressline_HEADERS
HEADER_NAMES
AddresseeLineEditUtil
REQUIRED_HEADERS libkdepim_addressline_HEADERS
PREFIX Libkdepim
RELATIVE addressline/addresslineedit/
)
ecm_generate_pri_file(BASE_NAME Libkdepim
......@@ -203,6 +213,7 @@ install(FILES
${libkdepim_Camelcasepref_HEADERS}
${libkdepim_Camelcasemultiline_HEADERS}
${libkdepim_Camelcaserecentaddress_HEADERS}
${libkdepim_Camelcaseaddressline_HEADERS}
DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/Libkdepim
COMPONENT Devel
)
......@@ -217,6 +228,7 @@ install(FILES
${libkdepim_pref_HEADERS}
${libkdepim_multiline_HEADERS}
${libkdepim_recentaddress_HEADERS}
${libkdepim_addressline_HEADERS}
DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/libkdepim
COMPONENT Devel
)
......
......@@ -21,12 +21,14 @@
#define ADDRESSEELINEEDITUTIL_H
#include <QString>
#include "libkdepimakonadi_private_export.h"
#include "kdepim_export.h"
namespace KPIM {
namespace AddresseeLineEditUtil {
LIBKDEPIMAKONADI_TESTS_EXPORT QString adaptPasteMails(QString str);
}
class KDEPIM_EXPORT AddresseeLineEditUtil
{
public:
static QString adaptPasteMails(QString str);
};
}
#endif // ADDRESSEELINEEDITUTIL_H
......@@ -18,3 +18,6 @@ endmacro()
add_libkdepim_addressline_unittest(recentaddresswidgettest
recentaddresswidgettest.cpp
)
add_libkdepim_addressline_unittest(addresseelineeditutiltest
addresseelineeditutiltest.cpp
)
......@@ -22,7 +22,6 @@ set(kdepim_addressline_LIB_SRCS
addressline/addresslineedit/kmailcompletion.cpp
addressline/addresslineedit/baloocompletionemail.cpp
addressline/completionconfiguredialog/completionconfiguredialog.cpp
addressline/addresslineedit/addresseelineeditutil.cpp
)
set(kdepim_addressline_blacklist_baloo_LIB_SRCS
......
......@@ -26,7 +26,7 @@
#include "addresseelineedit.h"
#include "addresseelineedit_p.h"
#include "addresseelineeditutil.h"
#include "Libkdepim/AddresseeLineEditUtil"
#include "ldap/ldapclientsearch.h"
#include <KContacts/VCardConverter>
......
......@@ -81,7 +81,7 @@ void KMailCompletion::addItemWithKeys(const QString &email, int weight, const QS
Q_ASSERT(keyWords != nullptr);
QStringList::ConstIterator end = keyWords->constEnd();
for (QStringList::ConstIterator it(keyWords->constBegin()); it != end; ++it) {
QStringList &emailList = m_keyMap[(*it) ]; //lookup email-list for given keyword
QStringList &emailList = m_keyMap[(*it)]; //lookup email-list for given keyword
if (!emailList.contains(email)) { //add email if not there
emailList.append(email);
}
......
......@@ -25,6 +25,3 @@ add_libkdepim_addressline_unittest(completionorderwidgettest
completionorderwidgettest.cpp
)
add_libkdepim_addressline_unittest(addresseelineeditutiltest
addresseelineeditutiltest.cpp
)
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