Commit b50aeccb authored by Laurent Montel's avatar Laurent Montel 😁

Use namespace here too

parent 8231745b
......@@ -35,7 +35,7 @@ class ContactGroup;
class KJob;
namespace LibImportWizard
{
class LIBIMPORTWIZARD_EXPORT AbstractAddressBook: public AbstractBase
class LIBIMPORTWIZARD_EXPORT AbstractAddressBook: public LibImportWizard::AbstractBase
{
Q_OBJECT
public:
......
......@@ -29,7 +29,7 @@
#include <QMetaMethod>
using namespace Akonadi;
using namespace LibImportWizard;
AbstractBase::AbstractBase()
{
mCreateResource = new PimCommon::CreateResource();
......@@ -42,7 +42,7 @@ AbstractBase::~AbstractBase()
delete mCreateResource;
}
QString AbstractBase::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings)
QString LibImportWizard::AbstractBase::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings)
{
return mCreateResource->createResource(resources, name, settings);
}
......
......@@ -30,7 +30,8 @@ namespace PimCommon
{
class CreateResource;
}
namespace LibImportWizard
{
class LIBIMPORTWIZARD_EXPORT AbstractBase : public QObject
{
Q_OBJECT
......@@ -49,5 +50,5 @@ private:
void slotCreateResourceInfo(const QString &);
PimCommon::CreateResource *mCreateResource;
};
}
#endif // ABSTRACTBASE_H
......@@ -26,7 +26,7 @@ class ImportWizard;
#include <QString>
namespace LibImportWizard
{
class LIBIMPORTWIZARD_EXPORT AbstractCalendar : public AbstractBase
class LIBIMPORTWIZARD_EXPORT AbstractCalendar : public LibImportWizard::AbstractBase
{
Q_OBJECT
public:
......
......@@ -38,7 +38,7 @@ namespace MailTransport
class Transport;
}
class LIBIMPORTWIZARD_EXPORT AbstractSettings : public AbstractBase
class LIBIMPORTWIZARD_EXPORT AbstractSettings : public LibImportWizard::AbstractBase
{
Q_OBJECT
public:
......
......@@ -82,7 +82,7 @@ void BalsaSettings::readAccount(const KConfigGroup &grp, bool autoCheck, int aut
//const bool apop = grp.readEntry(QStringLiteral("DisableApop"), false);
//Q_UNUSED(apop);
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, autoCheck);
addToManualCheck(agentIdentifyName, check);
......@@ -92,7 +92,7 @@ void BalsaSettings::readAccount(const KConfigGroup &grp, bool autoCheck, int aut
const QString server = grp.readEntry(QStringLiteral("Server"));
settings.insert(QStringLiteral("ImapServer"), server);
const QString name = grp.readEntry(QStringLiteral("Name"));
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, autoCheck);
addToManualCheck(agentIdentifyName, check);
} else {
......
......@@ -144,7 +144,7 @@ void EvolutionCalendar::extractCalendarInfo(const QString &info)
}
}
}
AbstractBase::createResource(QStringLiteral("akonadi_ical_resource"), name, settings);
LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_ical_resource"), name, settings);
} else {
//FIXME qCDebug(IMPORTWIZARD_LOG) << " tag unknown :" << tag;
}
......
......@@ -352,7 +352,7 @@ void EvolutionSettings::extractAccountInfo(const QString &info)
}
addAuth(settings, QStringLiteral("Authentication"), userName);
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
//By default
addCheckMailOnStartup(agentIdentifyName, enableManualCheck);
addToManualCheck(agentIdentifyName, enableManualCheck);
......@@ -384,7 +384,7 @@ void EvolutionSettings::extractAccountInfo(const QString &info)
settings.insert(QStringLiteral("LeaveOnServer"), true);
}
addAuth(settings, QStringLiteral("AuthenticationMethod"), userName);
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
//By default
addCheckMailOnStartup(agentIdentifyName, enableManualCheck);
addToManualCheck(agentIdentifyName, enableManualCheck);
......@@ -392,11 +392,11 @@ void EvolutionSettings::extractAccountInfo(const QString &info)
//mbox file
settings.insert(QStringLiteral("Path"), path);
settings.insert(QStringLiteral("DisplayName"), name);
AbstractBase::createResource(QStringLiteral("akonadi_mbox_resource"), name, settings);
LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_mbox_resource"), name, settings);
} else if (scheme == QLatin1String("maildir") || scheme == QLatin1String("spooldir")) {
settings.insert(QStringLiteral("Path"), path);
AbstractBase::createResource(QStringLiteral("akonadi_maildir_resource"), name, settings);
LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_maildir_resource"), name, settings);
} else if (scheme == QLatin1String("nntp")) {
//FIXME in the future
//FIXME qCDebug(IMPORTWIZARD_LOG) << " For the moment we can't import nntp resource";
......
......@@ -77,7 +77,7 @@ void GearySettings::readImapAccount()
}
if (!name.isEmpty()) {
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, newSettings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, newSettings);
//Check by default
addCheckMailOnStartup(agentIdentifyName, true);
}
......
......@@ -102,7 +102,7 @@ void OperaSettings::readAccount(const KConfigGroup &grp)
settings.insert(QStringLiteral("IntervalCheckTime"), pollInterval);
}
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
addToManualCheck(agentIdentifyName, enableManualCheck);
//We have not settings for it => same than manual check
addCheckMailOnStartup(agentIdentifyName, enableManualCheck);
......@@ -168,7 +168,7 @@ void OperaSettings::readAccount(const KConfigGroup &grp)
break;
}
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
//We have not settings for it => same than manual check
addCheckMailOnStartup(agentIdentifyName, enableManualCheck);
addToManualCheck(agentIdentifyName, enableManualCheck);
......
......@@ -355,7 +355,7 @@ void SylpheedSettings::readPop3Account(const KConfigGroup &accountConfig, bool c
settings.insert(QStringLiteral("IntervalCheckInterval"), intervalCheckMail);
}
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, checkMailOnStartup);
const bool enableManualCheck = (accountConfig.readEntry(QStringLiteral("receive_at_get_all"), 0) == 1);
addToManualCheck(agentIdentifyName, enableManualCheck);
......@@ -423,7 +423,7 @@ void SylpheedSettings::readImapAccount(const KConfigGroup &accountConfig, bool c
const QString password = accountConfig.readEntry(QStringLiteral("password"));
settings.insert(QStringLiteral("Password"), password);
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, checkMailOnStartup);
const bool enableManualCheck = (accountConfig.readEntry(QStringLiteral("receive_at_get_all"), 0) == 1);
......
......@@ -690,7 +690,7 @@ void ThunderbirdSettings::readAccount()
importSieveSettings(settings, userName, serverName);
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, loginAtStartup);
//Not find a method to disable it in thunderbird
addToManualCheck(agentIdentifyName, true);
......@@ -755,7 +755,7 @@ void ThunderbirdSettings::readAccount()
settings.insert(QStringLiteral("IntervalCheckInterval"), 10);
}
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_pop3_resource"), name, settings);
addCheckMailOnStartup(agentIdentifyName, loginAtStartup);
//Not find a method to disable it in thunderbird
addToManualCheck(agentIdentifyName, true);
......
......@@ -103,7 +103,7 @@ void TrojitaSettings::readImapAccount()
}
#endif
if (!name.isEmpty()) {
const QString agentIdentifyName = AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, newSettings);
const QString agentIdentifyName = LibImportWizard::AbstractBase::createResource(QStringLiteral("akonadi_imap_resource"), name, newSettings);
//Check by default
addCheckMailOnStartup(agentIdentifyName, true);
}
......
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