Mailcommon

addtagdialog.h
1 /*
2  SPDX-FileCopyrightText: 2012-2022 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include "mailcommon_export.h"
10 #include "tag.h"
11 #include <Akonadi/Tag>
12 #include <Akonadi/TagCreateJob>
13 #include <QDialog>
14 #include <QVector>
15 
16 class KActionCollection;
17 
18 namespace MailCommon
19 {
20 class AddTagDialogPrivate;
21 class MAILCOMMON_EXPORT AddTagDialog : public QDialog
22 {
23  Q_OBJECT
24 public:
25  explicit AddTagDialog(const QList<KActionCollection *> &actions, QWidget *parent = nullptr);
26  ~AddTagDialog() override;
27 
28  void setTags(const QVector<MailCommon::Tag::Ptr> &tags);
29  Q_REQUIRED_RESULT QString label() const;
30  Q_REQUIRED_RESULT Akonadi::Tag tag() const;
31 
32 private:
33  void slotSave();
34  void slotTagNameChanged(const QString &text);
35  void onTagCreated(KJob *job);
36  std::unique_ptr<AddTagDialogPrivate> const d;
37 };
38 }
QString label(StandardShortcut id)
The filter dialog.
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sat Oct 1 2022 04:00:52 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.