Messagelib

customtemplatesmenu.h
1/*
2 * SPDX-FileCopyrightText: 2006 Dmitry Morozhnikov <dmiceman@ubiz.ru>
3 *
4 * SPDX-License-Identifier: GPL-2.0-or-later
5 */
6
7#pragma once
8
9#include "templateparser_export.h"
10
11#include <QObject>
12#include <memory>
13
15class KActionMenu;
16
17namespace TemplateParser
18{
19class CustomTemplatesMenuPrivate;
20/**
21 * @brief The CustomTemplatesMenu class
22 */
23class TEMPLATEPARSER_EXPORT CustomTemplatesMenu : public QObject
24{
25 Q_OBJECT
26
27public:
28 explicit CustomTemplatesMenu(QWidget *parent, KActionCollection *ac);
29 ~CustomTemplatesMenu() override;
30
31 [[nodiscard]] KActionMenu *replyActionMenu() const;
32 [[nodiscard]] KActionMenu *replyAllActionMenu() const;
33 [[nodiscard]] KActionMenu *forwardActionMenu() const;
34
35public Q_SLOTS:
36 void update();
37
38Q_SIGNALS:
39 void replyTemplateSelected(const QString &tmpl);
40 void replyAllTemplateSelected(const QString &tmpl);
41 void forwardTemplateSelected(const QString &tmpl);
42
43private:
44 TEMPLATEPARSER_NO_EXPORT void slotReplySelected(int idx);
45 TEMPLATEPARSER_NO_EXPORT void slotReplyAllSelected(int idx);
46 TEMPLATEPARSER_NO_EXPORT void slotForwardSelected(int idx);
47 TEMPLATEPARSER_NO_EXPORT void clear();
48 std::unique_ptr<CustomTemplatesMenuPrivate> const d;
49};
50}
The CustomTemplatesMenu class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:33:26 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.