summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2017-10-25 22:51:35 +0200
committerMontel Laurent <[email protected]>2017-10-25 22:51:35 +0200
commitf675d22aef7b73ca8f272cf9c44828eae50bdc04 (patch)
tree18b5f61594827b7076e9a8bc0722f94db1734444
parent5303948528df99cc393329e8c36cd75ab74e18cd (diff)
Start to add support for select imap folder
-rw-r--r--src/ksieveui/CMakeLists.txt1
-rw-r--r--src/ksieveui/vacation/autotests/CMakeLists.txt1
-rw-r--r--src/ksieveui/vacation/autotests/vacationmailactionwidgettest.cpp29
-rw-r--r--src/ksieveui/vacation/autotests/vacationmailactionwidgettest.h33
-rw-r--r--src/ksieveui/vacation/vacationeditwidget.cpp1
-rw-r--r--src/ksieveui/vacation/vacationmailactionwidget.cpp34
-rw-r--r--src/ksieveui/vacation/vacationmailactionwidget.h34
7 files changed, 133 insertions, 0 deletions
diff --git a/src/ksieveui/CMakeLists.txt b/src/ksieveui/CMakeLists.txt
index b689531..82cf1ce 100644
--- a/src/ksieveui/CMakeLists.txt
+++ b/src/ksieveui/CMakeLists.txt
@@ -41,6 +41,7 @@ set(ksieveui_vacation_LIB_SRCS
vacation/vacationcheckjob.cpp
vacation/multiimapvacationmanager.cpp
vacation/vacationmanager.cpp
+ vacation/vacationmailactionwidget.cpp
vacation/legacy/vacationutils.cpp
vacation/legacy/vacationscriptextractor.cpp
)
diff --git a/src/ksieveui/vacation/autotests/CMakeLists.txt b/src/ksieveui/vacation/autotests/CMakeLists.txt
index 2dd2c3c..4956872 100644
--- a/src/ksieveui/vacation/autotests/CMakeLists.txt
+++ b/src/ksieveui/vacation/autotests/CMakeLists.txt
@@ -32,3 +32,4 @@ endmacro()
add_vacation_test(vacationutils)
add_vacation_test(vacationeditwidget)
add_vacation_test(vacationdialog)
+add_vacation_test(vacationmailactionwidget)
diff --git a/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.cpp b/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.cpp
new file mode 100644
index 0000000..6558437
--- /dev/null
+++ b/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.cpp
@@ -0,0 +1,29 @@
+/*
+ Copyright (C) 2017 Laurent Montel <[email protected]>
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ You should have received a copy of the GNU Library General Public License
+ along with this library; see the file COPYING.LIB. If not, write to
+ the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
+*/
+
+#include "vacationmailactionwidgettest.h"
+#include <QTest>
+
+QTEST_MAIN(VacationMailActionWidgetTest)
+
+VacationMailActionWidgetTest::VacationMailActionWidgetTest(QObject *parent)
+ : QObject(parent)
+{
+
+}
diff --git a/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.h b/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.h
new file mode 100644
index 0000000..bbad254
--- /dev/null
+++ b/src/ksieveui/vacation/autotests/vacationmailactionwidgettest.h
@@ -0,0 +1,33 @@
+/*
+ Copyright (C) 2017 Laurent Montel <[email protected]>
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ You should have received a copy of the GNU Library General Public License
+ along with this library; see the file COPYING.LIB. If not, write to
+ the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
+*/
+
+#ifndef VACATIONMAILACTIONWIDGETTEST_H
+#define VACATIONMAILACTIONWIDGETTEST_H
+
+#include <QObject>
+
+class VacationMailActionWidgetTest : public QObject
+{
+ Q_OBJECT
+public:
+ explicit VacationMailActionWidgetTest(QObject *parent = nullptr);
+ ~VacationMailActionWidgetTest() = default;
+};
+
+#endif // VACATIONMAILACTIONWIDGETTEST_H
diff --git a/src/ksieveui/vacation/vacationeditwidget.cpp b/src/ksieveui/vacation/vacationeditwidget.cpp
index 0c88b19..5efe574 100644
--- a/src/ksieveui/vacation/vacationeditwidget.cpp
+++ b/src/ksieveui/vacation/vacationeditwidget.cpp
@@ -175,6 +175,7 @@ VacationEditWidget::VacationEditWidget(QWidget *parent)
mMailAction->setObjectName(QStringLiteral("mMailAction"));
connect(mMailAction, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &VacationEditWidget::mailActionChanged);
+ //Add imap select folder plugin here.
mMailActionRecipient = new QLineEdit(this);
mMailActionRecipient->setObjectName(QStringLiteral("mMailActionRecipient"));
mMailActionRecipient->setClearButtonEnabled(true);
diff --git a/src/ksieveui/vacation/vacationmailactionwidget.cpp b/src/ksieveui/vacation/vacationmailactionwidget.cpp
new file mode 100644
index 0000000..af6f942
--- /dev/null
+++ b/src/ksieveui/vacation/vacationmailactionwidget.cpp
@@ -0,0 +1,34 @@
+/*
+ Copyright (C) 2017 Laurent Montel <[email protected]>
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ You should have received a copy of the GNU Library General Public License
+ along with this library; see the file COPYING.LIB. If not, write to
+ the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
+*/
+
+
+#include "vacationmailactionwidget.h"
+
+using namespace KSieveUi;
+
+VacationMailActionWidget::VacationMailActionWidget(QWidget *parent)
+ : QWidget(parent)
+{
+
+}
+
+VacationMailActionWidget::~VacationMailActionWidget()
+{
+
+}
diff --git a/src/ksieveui/vacation/vacationmailactionwidget.h b/src/ksieveui/vacation/vacationmailactionwidget.h
new file mode 100644
index 0000000..64115dc
--- /dev/null
+++ b/src/ksieveui/vacation/vacationmailactionwidget.h
@@ -0,0 +1,34 @@
+/*
+ Copyright (C) 2017 Laurent Montel <[email protected]>
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ You should have received a copy of the GNU Library General Public License
+ along with this library; see the file COPYING.LIB. If not, write to
+ the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
+*/
+
+#ifndef VACATIONMAILACTIONWIDGET_H
+#define VACATIONMAILACTIONWIDGET_H
+
+#include <QWidget>
+namespace KSieveUi {
+class VacationMailActionWidget : public QWidget
+{
+ Q_OBJECT
+public:
+ explicit VacationMailActionWidget(QWidget *parent = nullptr);
+ ~VacationMailActionWidget();
+};
+}
+
+#endif // VACATIONMAILACTIONWIDGET_H