File indexing completed on 2024-06-23 05:18:37

0001 /*
0002    SPDX-FileCopyrightText: 2020 Daniel Vrátil <dvratil@kde.org>
0003 
0004    SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #include "sendlaterremovejob.h"
0008 #include "sendlaterinterface.h"
0009 
0010 #include <KLocalizedString>
0011 
0012 using namespace MessageComposer;
0013 
0014 SendLaterRemoveJob::SendLaterRemoveJob(Akonadi::Item::Id item, QObject *parent)
0015     : SendLaterJob(parent)
0016     , mItem(item)
0017 {
0018 }
0019 
0020 QDBusPendingReply<> SendLaterRemoveJob::doCall(OrgFreedesktopAkonadiSendLaterAgentInterface *iface)
0021 {
0022     return iface->removeItem(mItem);
0023 }
0024 
0025 QString SendLaterRemoveJob::getErrorString(Error, const QString &detail) const
0026 {
0027     return i18n("Failed to removed message from send later schedule: %1", detail);
0028 }
0029 
0030 #include "moc_sendlaterremovejob.cpp"