Messagelib

itippart.cpp
1/*
2 SPDX-FileCopyrightText: 2023 Daniel Vrátil <dvratil@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#include "itippart.h"
8
9using namespace MessageComposer;
10
11class ItipPart::ItipPartPrivate
12{
13public:
14 QString invitation;
15 QString invitationBody;
16 QString method = QStringLiteral("request");
17 bool outlookComnformInvitation = false;
18};
19
20ItipPart::ItipPart(QObject *parent)
21 : MessagePart(parent)
22 , d(std::make_unique<ItipPartPrivate>())
23{
24}
25
26ItipPart::~ItipPart() = default;
27
28bool ItipPart::outlookConformInvitation() const
29{
30 return d->outlookComnformInvitation;
31}
32
33void ItipPart::setOutlookConformInvitation(bool enabled)
34{
35 if (d->outlookComnformInvitation == enabled) {
36 return;
37 }
38
39 d->outlookComnformInvitation = enabled;
40 Q_EMIT outlookConformInvitationChanged();
41}
42
43QString ItipPart::method() const
44{
45 return d->method;
46}
47
48void ItipPart::setMethod(const QString &method)
49{
50 if (d->method == method) {
51 return;
52 }
53
54 d->method = method;
55 Q_EMIT methodChanged();
56}
57
58QString ItipPart::invitation() const
59{
60 return d->invitation;
61}
62
63void ItipPart::setInvitation(const QString &invitation)
64{
65 if (d->invitation == invitation) {
66 return;
67 }
68
69 d->invitation = invitation;
70 Q_EMIT invitationChanged();
71}
72
73QString ItipPart::invitationBody() const
74{
75 return d->invitationBody;
76}
77
78void ItipPart::setInvitationBody(const QString &invitationBody)
79{
80 if (d->invitationBody == invitationBody) {
81 return;
82 }
83
84 d->invitationBody = invitationBody;
85 Q_EMIT invitationBodyChanged();
86}
87
88#include "moc_itippart.cpp"
Simple interface that both EncryptJob and SignEncryptJob implement so the composer can extract some e...
Q_EMITQ_EMIT
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:33:25 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.