Commit 0b2155e1 authored by Volker Krause's avatar Volker Krause
Browse files

Use calendar item access utility methods from akonadi-calendar

parent 18c6631c
Pipeline #167238 passed with stage
in 5 minutes and 56 seconds
......@@ -45,7 +45,7 @@ set(LIBKDEPIM_LIB_VERSION "5.20.40")
set(EVENTVIEW_LIB_VERSION "5.20.40")
set(AKONADI_VERSION "5.20.40")
set(AKONADICONTACT_LIB_VERSION "5.20.40")
set(AKONADICALENDAR_LIB_VERSION "5.20.40")
set(AKONADICALENDAR_LIB_VERSION "5.20.42")
set(PIMCOMMON_LIB_VERSION "5.20.40")
set(KDIAGRAM_LIB_VERSION "1.4.0")
......
......@@ -9,8 +9,8 @@
#include "individualmailcomponentfactory.h"
#include <CalendarSupport/KCalPrefs>
#include <CalendarSupport/Utils>
#include <Akonadi/CalendarUtils>
#include <Akonadi/Item>
#include <Akonadi/ItemDeleteJob>
#include <Akonadi/ItemFetchJob>
......@@ -315,7 +315,7 @@ void EditorItemManager::save()
if (d->mItem.isValid()) { // A valid item. Means we're modifying.
Q_ASSERT(d->mItem.parentCollection().isValid());
KCalendarCore::Incidence::Ptr oldPayload = CalendarSupport::incidence(d->mPrevItem);
KCalendarCore::Incidence::Ptr oldPayload = Akonadi::CalendarUtils::incidence(d->mPrevItem);
if (d->mItem.parentCollection() == d->mItemUi->selectedCollection() || d->mItem.storageCollectionId() == d->mItemUi->selectedCollection().id()) {
(void)d->mChanger->modifyIncidence(d->mItem, oldPayload);
} else {
......
......@@ -7,10 +7,9 @@
#include "groupwareuidelegate.h"
#include "incidencedialog.h"
#include "incidencedialogfactory.h"
#include <CalendarSupport/Utils>
#include "incidenceeditor_debug.h"
#include <Akonadi/CalendarUtils>
#include <Akonadi/Item>
using namespace IncidenceEditorNG;
......@@ -20,7 +19,7 @@ void GroupwareUiDelegate::requestIncidenceEditor(const Akonadi::Item &item)
// The GroupwareUiDelegate interface should be a QObject. Right now we have no way of emitting a
// finished signal, so we have to use dialog->exec();
const KCalendarCore::Incidence::Ptr incidence = CalendarSupport::incidence(item);
const KCalendarCore::Incidence::Ptr incidence = Akonadi::CalendarUtils::incidence(item);
if (!incidence) {
qCWarning(INCIDENCEEDITOR_LOG) << "Incidence is null, won't open the editor";
return;
......
......@@ -12,8 +12,7 @@
#include "incidenceeditor_debug.h"
#include "ui_dialogdesktop.h"
#include <CalendarSupport/Utils>
#include <Akonadi/CalendarUtils>
#include <Akonadi/TagAttribute>
#include <Akonadi/TagCreateJob>
#include <Akonadi/TagFetchJob>
......@@ -45,7 +44,7 @@ void IncidenceCategories::load(const KCalendarCore::Incidence::Ptr &incidence)
void IncidenceCategories::load(const Akonadi::Item &item)
{
mLoadedIncidence = CalendarSupport::incidence(item);
mLoadedIncidence = Akonadi::CalendarUtils::incidence(item);
mDirty = false;
mWasDirty = false;
......
......@@ -29,6 +29,7 @@
#include <CalendarSupport/KCalPrefs>
#include <CalendarSupport/Utils>
#include <Akonadi/CalendarUtils>
#include <Akonadi/CollectionComboBox>
#include <Akonadi/ETMCalendar>
#include <Akonadi/EntityTreeModel>
......@@ -497,7 +498,7 @@ void IncidenceDialogPrivate::handleItemSaveFinish(EditorItemManager::SaveAction
bool IncidenceDialogPrivate::hasSupportedPayload(const Akonadi::Item &item) const
{
return !CalendarSupport::incidence(item).isNull();
return Akonadi::CalendarUtils::incidence(item).isNull();
}
bool IncidenceDialogPrivate::isDirty() const
......@@ -540,10 +541,10 @@ void IncidenceDialogPrivate::load(const Akonadi::Item &item)
mUi->mTabWidget->removeTab(ResourcesTab);
}
mEditor->load(CalendarSupport::incidence(item));
mEditor->load(Akonadi::CalendarUtils::incidence(item));
mEditor->load(item);
const KCalendarCore::Incidence::Ptr incidence = CalendarSupport::incidence(item);
const KCalendarCore::Incidence::Ptr incidence = Akonadi::CalendarUtils::incidence(item);
const QStringList allEmails = IncidenceEditorNG::EditorConfig::instance()->allEmails();
const KCalendarCore::Attendee me = incidence->attendeeByMails(allEmails);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment