Libksieve

moveimapfolderwidget.cpp
1 /*
2  SPDX-FileCopyrightText: 2016-2021 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #include "moveimapfolderwidget.h"
8 #include <KLocalizedString>
9 #include <Libkdepim/LineEditCatchReturnKey>
10 #include <QHBoxLayout>
11 #include <QLineEdit>
12 using namespace KSieveUi;
13 
14 MoveImapFolderWidget::MoveImapFolderWidget(QWidget *parent)
16  , mLineEdit(new QLineEdit(this))
17 {
18  auto mainLayout = new QHBoxLayout(this);
19  mainLayout->setObjectName(QStringLiteral("mainlayout"));
20  mainLayout->setContentsMargins({});
21  new KPIM::LineEditCatchReturnKey(mLineEdit, this);
22  mLineEdit->setObjectName(QStringLiteral("lineedit"));
23  mLineEdit->setClearButtonEnabled(true);
24  mLineEdit->setPlaceholderText(i18n("Define Folder"));
25  mainLayout->addWidget(mLineEdit);
26  connect(mLineEdit, &QLineEdit::textChanged, this, &MoveImapFolderWidget::textChanged);
27 }
28 
29 MoveImapFolderWidget::~MoveImapFolderWidget()
30 {
31 }
32 
33 void MoveImapFolderWidget::setText(const QString &str)
34 {
35  mLineEdit->setText(str);
36 }
37 
38 QString MoveImapFolderWidget::text() const
39 {
40  return mLineEdit->text();
41 }
42 
43 void MoveImapFolderWidget::setSieveImapAccountSettings(const KSieveUi::SieveImapAccountSettings &account)
44 {
45  Q_UNUSED(account)
46 }
void textChanged(const QString &text)
The AbstractMoveImapFolderWidget class.
QString i18n(const char *text, const TYPE &arg...)
The SieveImapAccountSettings class.
QMetaObject::Connection connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Fri Apr 16 2021 23:09:33 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.