Akonadi Calendar
calendarclipboard.cpp
19CalendarClipboardPrivate::CalendarClipboardPrivate(const Akonadi::CalendarBase::Ptr &calendar, Akonadi::IncidenceChanger *changer, CalendarClipboard *qq)
34 connect(m_changer, &IncidenceChanger::modifyFinished, this, &CalendarClipboardPrivate::slotModifyFinished);
36 connect(m_changer, &IncidenceChanger::deleteFinished, this, &CalendarClipboardPrivate::slotDeleteFinished);
44void CalendarClipboardPrivate::getIncidenceHierarchy(const KCalendarCore::Incidence::Ptr &incidence, QStringList &uids)
48 const KCalendarCore::Incidence::List immediateChildren = m_calendar->childIncidences(incidence->uid());
83void CalendarClipboardPrivate::makeChildsIndependent(const KCalendarCore::Incidence::Ptr &incidence)
117void CalendarClipboardPrivate::slotModifyFinished(int changeId, const Akonadi::Item &item, IncidenceChanger::ResultCode resultCode, const QString &errorMessage)
158 Q_EMIT q->cutFinished(/**success=*/false, i18n("Error while deleting incidences: %1", errorMessage));
162CalendarClipboard::CalendarClipboard(const Akonadi::CalendarBase::Ptr &calendar, Akonadi::IncidenceChanger *changer, QObject *parent)
170void CalendarClipboard::cutIncidence(const KCalendarCore::Incidence::Ptr &incidence, CalendarClipboard::Mode mode)
210bool CalendarClipboard::copyIncidence(const KCalendarCore::Incidence::Ptr &incidence, CalendarClipboard::Mode mode)
Class to copy or cut calendar incidences.
Definition calendarclipboard.h:29
@ AskMode
The user is asked if he wants children to be cut/copied too.
Definition calendarclipboard.h:35
@ RecursiveMode
The specified incidence's children are also cut/copied.
Definition calendarclipboard.h:34
~CalendarClipboard() override
Destroys the CalendarClipboard instance.
void cutFinished(bool success, const QString &errorMessage)
Emitted after cutIncidences() finishes.
CalendarClipboard(const Akonadi::CalendarBase::Ptr &calendar, Akonadi::IncidenceChanger *changer=nullptr, QObject *parent=nullptr)
Constructs a new CalendarClipboard.
Definition calendarclipboard.cpp:162
void cutIncidence(const KCalendarCore::Incidence::Ptr &incidence, CalendarClipboard::Mode mode=RecursiveMode)
Copies the specified incidence into the clipboard and then deletes it from akonadi.
Definition calendarclipboard.cpp:170
bool pasteAvailable() const
Returns if there's any ical mime data available for pasting.
Definition calendarclipboard.cpp:248
bool copyIncidence(const KCalendarCore::Incidence::Ptr &incidence, CalendarClipboard::Mode mode=RecursiveMode)
Copies the specified incidence into the clipboard.
Definition calendarclipboard.cpp:210
T payload() const
Id id() const
bool isValid() const
void setPayload(const T &p)
bool hasPayload() const
QString i18nc(const char *context, const char *text, const TYPE &arg...)
QString i18n(const char *text, const TYPE &arg...)
AKONADI_CALENDAR_EXPORT KCalendarCore::Incidence::Ptr incidence(const Akonadi::Item &item)
Returns the incidence from an Akonadi item, or a null pointer if the item has no such payload.
Definition calendarutils.cpp:28
FreeBusyManager::Singleton.
KCALUTILS_EXPORT bool canDecode(const QMimeData *)
Cancel
ButtonCode questionTwoActionsCancel(QWidget *parent, const QString &text, const QString &title, const KGuiItem &primaryAction, const KGuiItem &secondaryAction, const KGuiItem &cancelAction=KStandardGuiItem::cancel(), const QString &dontAskAgainName=QString(), Options options=Notify)
const QList< QKeySequence > & cut()
QClipboard * clipboard()
void append(QList< T > &&value)
bool isEmpty() const const
void remove(qsizetype i, qsizetype n)
Q_EMITQ_EMIT
bool contains(QLatin1StringView str, Qt::CaseSensitivity cs) const const
QFuture< ArgsType< Signal > > connect(Sender *sender, Signal signal)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 1 2024 18:47:32 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 1 2024 18:47:32 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.