Commit 94e4c571 authored by Laurent Montel's avatar Laurent Montel 😁

Coding style

parent 0ab254e5
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
using namespace KSieveUi; using namespace KSieveUi;
SieveDebugDialog::SieveDebugDialog(SieveImapPasswordProvider* passwordProvider, QWidget *parent) SieveDebugDialog::SieveDebugDialog(SieveImapPasswordProvider *passwordProvider, QWidget *parent)
: QDialog(parent) : QDialog(parent)
, mSieveJob(nullptr) , mSieveJob(nullptr)
, mPasswordProvider(passwordProvider) , mPasswordProvider(passwordProvider)
......
...@@ -29,7 +29,6 @@ namespace KPIMTextEdit { ...@@ -29,7 +29,6 @@ namespace KPIMTextEdit {
class PlainTextEditorWidget; class PlainTextEditorWidget;
} }
namespace KSieveUi { namespace KSieveUi {
class SieveImapPasswordProvider; class SieveImapPasswordProvider;
/** /**
...@@ -40,7 +39,7 @@ class KSIEVEUI_EXPORT SieveDebugDialog : public QDialog ...@@ -40,7 +39,7 @@ class KSIEVEUI_EXPORT SieveDebugDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT
public: public:
explicit SieveDebugDialog(SieveImapPasswordProvider* passwordProvider, QWidget *parent = nullptr); explicit SieveDebugDialog(SieveImapPasswordProvider *passwordProvider, QWidget *parent = nullptr);
~SieveDebugDialog(); ~SieveDebugDialog();
Q_SIGNALS: Q_SIGNALS:
...@@ -61,7 +60,7 @@ private: ...@@ -61,7 +60,7 @@ private:
QUrl mUrl; QUrl mUrl;
KSyntaxHighlighting::Repository mRepo; KSyntaxHighlighting::Repository mRepo;
SieveImapPasswordProvider* mPasswordProvider; SieveImapPasswordProvider *mPasswordProvider;
KPIMTextEdit::PlainTextEditorWidget *mEdit; KPIMTextEdit::PlainTextEditorWidget *mEdit;
QStringList mResourceIdentifier; QStringList mResourceIdentifier;
QStringList mScriptList; QStringList mScriptList;
......
...@@ -39,7 +39,7 @@ class KSIEVEUI_EXPORT ManageSieveScriptsDialog : public QDialog ...@@ -39,7 +39,7 @@ class KSIEVEUI_EXPORT ManageSieveScriptsDialog : public QDialog
Q_OBJECT Q_OBJECT
public: public:
explicit ManageSieveScriptsDialog(SieveImapPasswordProvider* passwordProvider, QWidget *parent = nullptr); explicit ManageSieveScriptsDialog(SieveImapPasswordProvider *passwordProvider, QWidget *parent = nullptr);
~ManageSieveScriptsDialog(); ~ManageSieveScriptsDialog();
Q_SIGNALS: Q_SIGNALS:
......
...@@ -30,16 +30,16 @@ class DataImapPasswordProvider : public KSieveUi::SieveImapPasswordProvider ...@@ -30,16 +30,16 @@ class DataImapPasswordProvider : public KSieveUi::SieveImapPasswordProvider
{ {
public: public:
DataImapPasswordProvider(AkonadiImapSettingInterfaceDataTest *data) DataImapPasswordProvider(AkonadiImapSettingInterfaceDataTest *data)
: mData(data) : mData(data)
{ {
} }
QString password(const QString &/*identifier*/) override QString password(const QString & /*identifier*/) override
{ {
return mData->password; return mData->password;
} }
QString sieveCustomPassword(const QString &/*identifier*/) override QString sieveCustomPassword(const QString & /*identifier*/) override
{ {
return mData->sieveCustomPassword; return mData->sieveCustomPassword;
} }
......
...@@ -24,9 +24,7 @@ ...@@ -24,9 +24,7 @@
class QString; class QString;
namespace KSieveUi namespace KSieveUi {
{
class KSIEVEUI_EXPORT SieveImapPasswordProvider class KSIEVEUI_EXPORT SieveImapPasswordProvider
{ {
public: public:
...@@ -34,6 +32,5 @@ public: ...@@ -34,6 +32,5 @@ public:
virtual QString password(const QString &identifier) = 0; virtual QString password(const QString &identifier) = 0;
virtual QString sieveCustomPassword(const QString &identifier) = 0; virtual QString sieveCustomPassword(const QString &identifier) = 0;
}; };
} }
#endif #endif
...@@ -61,7 +61,8 @@ KSieveUi::Util::AccountInfo KSieveUi::Util::fullAccountInfo(const QString &ident ...@@ -61,7 +61,8 @@ KSieveUi::Util::AccountInfo KSieveUi::Util::fullAccountInfo(const QString &ident
return accountInfo; return accountInfo;
} }
KSieveUi::Util::AccountInfo KSieveUi::Util::findAccountInfo(const QString &identifier, SieveImapPasswordProvider *provider, bool withVacationFileName, std::unique_ptr<KSieveUi::AbstractAkonadiImapSettingInterface> &interface) KSieveUi::Util::AccountInfo KSieveUi::Util::findAccountInfo(const QString &identifier, SieveImapPasswordProvider *provider, bool withVacationFileName,
std::unique_ptr<KSieveUi::AbstractAkonadiImapSettingInterface> &interface)
{ {
KSieveUi::Util::AccountInfo accountInfo; KSieveUi::Util::AccountInfo accountInfo;
if (!interface) { if (!interface) {
......
...@@ -80,7 +80,8 @@ bool hasKep14Support(const QStringList &sieveCapabilities, const QStringList &av ...@@ -80,7 +80,8 @@ bool hasKep14Support(const QStringList &sieveCapabilities, const QStringList &av
*/ */
bool isKep14ProtectedName(const QString &scriptName); bool isKep14ProtectedName(const QString &scriptName);
KSIEVEUI_TESTS_EXPORT KSieveUi::Util::AccountInfo findAccountInfo(const QString &identifier, SieveImapPasswordProvider *provider, bool withVacationFileName, std::unique_ptr<KSieveUi::AbstractAkonadiImapSettingInterface> &interface); KSIEVEUI_TESTS_EXPORT KSieveUi::Util::AccountInfo findAccountInfo(const QString &identifier, SieveImapPasswordProvider *provider, bool withVacationFileName,
std::unique_ptr<KSieveUi::AbstractAkonadiImapSettingInterface> &interface);
/** /**
* Returns all sieve account info with the given @p identifier. * Returns all sieve account info with the given @p identifier.
*/ */
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
#include "libksieve_debug.h" #include "libksieve_debug.h"
using namespace KSieveUi; using namespace KSieveUi;
MultiImapVacationManager::MultiImapVacationManager(SieveImapPasswordProvider* passwordProvider, QObject *parent) MultiImapVacationManager::MultiImapVacationManager(SieveImapPasswordProvider *passwordProvider, QObject *parent)
: QObject(parent) : QObject(parent)
, mPasswordProvider(passwordProvider) , mPasswordProvider(passwordProvider)
, mNumberOfJobs(0) , mNumberOfJobs(0)
......
...@@ -35,7 +35,7 @@ class KSIEVEUI_EXPORT MultiImapVacationManager : public QObject ...@@ -35,7 +35,7 @@ class KSIEVEUI_EXPORT MultiImapVacationManager : public QObject
{ {
Q_OBJECT Q_OBJECT
public: public:
explicit MultiImapVacationManager(SieveImapPasswordProvider* passwordProvider, QObject *parent = nullptr); explicit MultiImapVacationManager(SieveImapPasswordProvider *passwordProvider, QObject *parent = nullptr);
~MultiImapVacationManager(); ~MultiImapVacationManager();
void checkVacation(); void checkVacation();
...@@ -52,7 +52,7 @@ private Q_SLOTS: ...@@ -52,7 +52,7 @@ private Q_SLOTS:
void slotCheckKep14Ended(KSieveUi::CheckKolabKep14SupportJob *job, bool success); void slotCheckKep14Ended(KSieveUi::CheckKolabKep14SupportJob *job, bool success);
private: private:
SieveImapPasswordProvider* mPasswordProvider; SieveImapPasswordProvider *mPasswordProvider;
int mNumberOfJobs; int mNumberOfJobs;
bool mCheckInProgress; bool mCheckInProgress;
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
using namespace KSieveUi; using namespace KSieveUi;
Vacation::Vacation(SieveImapPasswordProvider* passwordProvider, QObject *parent, bool checkOnly, const QUrl &url) Vacation::Vacation(SieveImapPasswordProvider *passwordProvider, QObject *parent, bool checkOnly, const QUrl &url)
: QObject(parent) : QObject(parent)
, mPasswordProvider(passwordProvider) , mPasswordProvider(passwordProvider)
, mSieveJob(nullptr) , mSieveJob(nullptr)
......
...@@ -33,7 +33,7 @@ class Vacation : public QObject ...@@ -33,7 +33,7 @@ class Vacation : public QObject
Q_OBJECT Q_OBJECT
public: public:
explicit Vacation(SieveImapPasswordProvider* passwordProvider, QObject *parent = nullptr, bool checkonly = false, const QUrl &url = QUrl()); explicit Vacation(SieveImapPasswordProvider *passwordProvider, QObject *parent = nullptr, bool checkonly = false, const QUrl &url = QUrl());
virtual ~Vacation(); virtual ~Vacation();
bool isUsable() const; bool isUsable() const;
...@@ -59,7 +59,7 @@ protected Q_SLOTS: ...@@ -59,7 +59,7 @@ protected Q_SLOTS:
void slotPutInactiveResult(KManageSieve::SieveJob *, bool); void slotPutInactiveResult(KManageSieve::SieveJob *, bool);
protected: protected:
// IO: // IO:
SieveImapPasswordProvider* mPasswordProvider; SieveImapPasswordProvider *mPasswordProvider;
KManageSieve::SieveJob *mSieveJob; KManageSieve::SieveJob *mSieveJob;
QUrl mUrl; QUrl mUrl;
QString mServerName; QString mServerName;
......
...@@ -44,7 +44,7 @@ public: ...@@ -44,7 +44,7 @@ public:
bool mQuestionAsked; bool mQuestionAsked;
}; };
VacationManager::VacationManager(SieveImapPasswordProvider* passwordProvider, QWidget *parent) VacationManager::VacationManager(SieveImapPasswordProvider *passwordProvider, QWidget *parent)
: QObject(parent) : QObject(parent)
, d(new KSieveUi::VacationManagerPrivate(parent)) , d(new KSieveUi::VacationManagerPrivate(parent))
{ {
......
...@@ -32,7 +32,7 @@ class KSIEVEUI_EXPORT VacationManager : public QObject ...@@ -32,7 +32,7 @@ class KSIEVEUI_EXPORT VacationManager : public QObject
{ {
Q_OBJECT Q_OBJECT
public: public:
explicit VacationManager(SieveImapPasswordProvider* passwordProvider, QWidget *parent); explicit VacationManager(SieveImapPasswordProvider *passwordProvider, QWidget *parent);
~VacationManager(); ~VacationManager();
void checkVacation(); void checkVacation();
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
using namespace KSieveUi; using namespace KSieveUi;
CustomManageSieveWidget::CustomManageSieveWidget(SieveImapPasswordProvider* passwordProvider, QWidget *parent) CustomManageSieveWidget::CustomManageSieveWidget(SieveImapPasswordProvider *passwordProvider, QWidget *parent)
: KSieveUi::ManageSieveWidget(parent) : KSieveUi::ManageSieveWidget(parent)
, mPasswordProvider(passwordProvider) , mPasswordProvider(passwordProvider)
{ {
......
...@@ -26,14 +26,14 @@ class CustomManageSieveWidget : public KSieveUi::ManageSieveWidget ...@@ -26,14 +26,14 @@ class CustomManageSieveWidget : public KSieveUi::ManageSieveWidget
{ {
Q_OBJECT Q_OBJECT
public: public:
explicit CustomManageSieveWidget(SieveImapPasswordProvider* passwordProvider, QWidget *parent = nullptr); explicit CustomManageSieveWidget(SieveImapPasswordProvider *passwordProvider, QWidget *parent = nullptr);
virtual ~CustomManageSieveWidget(); virtual ~CustomManageSieveWidget();
protected: protected:
bool refreshList() override; bool refreshList() override;
private: private:
SieveImapPasswordProvider* mPasswordProvider; SieveImapPasswordProvider *mPasswordProvider;
}; };
} }
......
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