Commit 3ab10c31 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Add selector

parent 34e1203f
......@@ -35,4 +35,8 @@ void DKIMAuthenticationVerifiedServerWidgetTest::shouldHaveDefaultValues()
QVBoxLayout *mainLayout = w.findChild<QVBoxLayout *>(QStringLiteral("mainLayout"));
QVERIFY(mainLayout);
QCOMPARE(mainLayout->contentsMargins(), QMargins(0, 0, 0, 0));
DKIMAuthenticationVerifiedServerSelectorWidget *mSelector = w.findChild<DKIMAuthenticationVerifiedServerSelectorWidget *>(QStringLiteral("mSelector"));
QVERIFY(mSelector);
}
......@@ -28,6 +28,9 @@ DKIMAuthenticationVerifiedServerWidget::DKIMAuthenticationVerifiedServerWidget(Q
mainLayout->setObjectName(QStringLiteral("mainLayout"));
mainLayout->setContentsMargins(0, 0, 0, 0);
mSelector = new DKIMAuthenticationVerifiedServerSelectorWidget(this);
mSelector->setObjectName(QStringLiteral("mSelector"));
mainLayout->addWidget(mSelector);
}
DKIMAuthenticationVerifiedServerWidget::~DKIMAuthenticationVerifiedServerWidget()
......@@ -44,3 +47,19 @@ void DKIMAuthenticationVerifiedServerWidget::saveSettings()
{
//TODO
}
DKIMAuthenticationVerifiedServerSelectorWidget::DKIMAuthenticationVerifiedServerSelectorWidget(QWidget *parent)
: PimCommon::SimpleStringListEditor(parent)
{
}
DKIMAuthenticationVerifiedServerSelectorWidget::~DKIMAuthenticationVerifiedServerSelectorWidget()
{
}
void DKIMAuthenticationVerifiedServerSelectorWidget::addNewEntry()
{
}
......@@ -22,6 +22,17 @@
#include <QWidget>
#include "dkimconfigure_private_export.h"
#include <PimCommon/SimpleStringListEditor>
class LIBDKIMVERIFYCONFIGURE_TESTS_EXPORT DKIMAuthenticationVerifiedServerSelectorWidget : public PimCommon::SimpleStringListEditor
{
Q_OBJECT
public:
explicit DKIMAuthenticationVerifiedServerSelectorWidget(QWidget *parent = nullptr);
~DKIMAuthenticationVerifiedServerSelectorWidget();
void addNewEntry() override;
};
class LIBDKIMVERIFYCONFIGURE_TESTS_EXPORT DKIMAuthenticationVerifiedServerWidget : public QWidget
{
......@@ -31,6 +42,8 @@ public:
~DKIMAuthenticationVerifiedServerWidget();
void loadSettings();
void saveSettings();
private:
DKIMAuthenticationVerifiedServerSelectorWidget *mSelector = nullptr;
};
#endif // DKIMAUTHENTICATIONVERIFIEDSERVERWIDGET_H
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