Commit ace6da18 authored by Daniel Vrátil's avatar Daniel Vrátil 🤖
Browse files

Add CollectionMaintenancePage to Folder Properties dialog

Mostly to be able to control whether to index events from the
calendar and to be able to force re-indexing.
parent 41084fd9
...@@ -49,7 +49,7 @@ set(AKONADICALENDAR_LIB_VERSION "5.5.40") ...@@ -49,7 +49,7 @@ set(AKONADICALENDAR_LIB_VERSION "5.5.40")
set(KONTACTINTERFACE_LIB_VERSION "5.5.40") set(KONTACTINTERFACE_LIB_VERSION "5.5.40")
set(KMIME_LIB_VERSION "5.5.40") set(KMIME_LIB_VERSION "5.5.40")
set(KPIMTEXTEDIT_LIB_VERSION "5.5.40") set(KPIMTEXTEDIT_LIB_VERSION "5.5.40")
set(AKONADI_VERSION "5.5.40") set(AKONADI_VERSION "5.5.42")
set(KDEPIM_LIB_VERSION "${KDEPIM_VERSION_NUMBER}") set(KDEPIM_LIB_VERSION "${KDEPIM_VERSION_NUMBER}")
set(KDEPIM_LIB_SOVERSION "5") set(KDEPIM_LIB_SOVERSION "5")
......
...@@ -77,6 +77,7 @@ ...@@ -77,6 +77,7 @@
#include <AkonadiWidgets/CollectionPropertiesDialog> #include <AkonadiWidgets/CollectionPropertiesDialog>
#include <AkonadiWidgets/ControlGui> #include <AkonadiWidgets/ControlGui>
#include <AkonadiWidgets/CollectionMaintenancePage>
#include <AkonadiCore/AttributeFactory> #include <AkonadiCore/AttributeFactory>
#include <Akonadi/Calendar/TodoPurger> #include <Akonadi/Calendar/TodoPurger>
...@@ -300,6 +301,7 @@ CalendarView::CalendarView(QWidget *parent) ...@@ -300,6 +301,7 @@ CalendarView::CalendarView(QWidget *parent)
Akonadi::CollectionPropertiesDialog::registerPage( Akonadi::CollectionPropertiesDialog::registerPage(
new CalendarSupport::CollectionGeneralPageFactory); new CalendarSupport::CollectionGeneralPageFactory);
Akonadi::CollectionPropertiesDialog::registerPage(new PimCommon::CollectionAclPageFactory); Akonadi::CollectionPropertiesDialog::registerPage(new PimCommon::CollectionAclPageFactory);
Akonadi::CollectionPropertiesDialog::registerPage(new Akonadi::CollectionMaintenancePageFactory);
pageRegistered = true; pageRegistered = true;
} }
} }
......
...@@ -21,8 +21,10 @@ ...@@ -21,8 +21,10 @@
#include "akonadicollectionview.h" #include "akonadicollectionview.h"
#include "korganizer_debug.h" #include "korganizer_debug.h"
#include <AkonadiWidgets/CollectionPropertiesDialog> #include <AkonadiWidgets/CollectionPropertiesDialog>
#include <AkonadiWidgets/CollectionMaintenancePage>
#include <AkonadiCore/CollectionAttributesSynchronizationJob> #include <AkonadiCore/CollectionAttributesSynchronizationJob>
#include <AkonadiCore/CollectionFetchJob> #include <AkonadiCore/CollectionFetchJob>
#include <AkonadiCore/CollectionFetchScope>
ManageShowCollectionProperties::ManageShowCollectionProperties(AkonadiCollectionView *collectionView, QObject *parent) ManageShowCollectionProperties::ManageShowCollectionProperties(AkonadiCollectionView *collectionView, QObject *parent)
: QObject(parent), : QObject(parent),
...@@ -30,7 +32,8 @@ ManageShowCollectionProperties::ManageShowCollectionProperties(AkonadiCollection ...@@ -30,7 +32,8 @@ ManageShowCollectionProperties::ManageShowCollectionProperties(AkonadiCollection
{ {
mPages = QStringList() << QStringLiteral("CalendarSupport::CollectionGeneralPage") mPages = QStringList() << QStringLiteral("CalendarSupport::CollectionGeneralPage")
<< QStringLiteral("Akonadi::CachePolicyPage") << QStringLiteral("Akonadi::CachePolicyPage")
<< QStringLiteral("PimCommon::CollectionAclPage"); << QStringLiteral("PimCommon::CollectionAclPage")
<< QStringLiteral("Akonadi::CollectionMaintenancePage");
} }
ManageShowCollectionProperties::~ManageShowCollectionProperties() ManageShowCollectionProperties::~ManageShowCollectionProperties()
...@@ -68,6 +71,7 @@ void ManageShowCollectionProperties::slotCollectionPropertiesContinued(KJob *job ...@@ -68,6 +71,7 @@ void ManageShowCollectionProperties::slotCollectionPropertiesContinued(KJob *job
} }
Akonadi::CollectionFetchJob *fetch = new Akonadi::CollectionFetchJob(mCollectionView->currentCalendar(), Akonadi::CollectionFetchJob *fetch = new Akonadi::CollectionFetchJob(mCollectionView->currentCalendar(),
Akonadi::CollectionFetchJob::Base); Akonadi::CollectionFetchJob::Base);
fetch->fetchScope().setIncludeStatistics(true);
connect(fetch, &KJob::result, connect(fetch, &KJob::result,
this, &ManageShowCollectionProperties::slotCollectionPropertiesFinished); this, &ManageShowCollectionProperties::slotCollectionPropertiesFinished);
} }
......
Markdown is supported
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