Commit 2eafae82 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Add code for importing calendar

parent d82d3480
......@@ -17,8 +17,10 @@
#include "evolutioncalendar.h"
EvolutionCalendar::EvolutionCalendar()
EvolutionCalendar::EvolutionCalendar(const QString& file,ImportWizard *parent)
:AbstractCalendar(parent)
{
//TODO
}
EvolutionCalendar::~EvolutionCalendar()
......
......@@ -18,10 +18,14 @@
#ifndef EVOLUTIONCALENDAR_H
#define EVOLUTIONCALENDAR_H
class EvolutionCalendar
#include "abstractcalendar.h"
class ImportWizard;
class EvolutionCalendar : public AbstractCalendar
{
public:
explicit EvolutionCalendar();
explicit EvolutionCalendar(const QString &file, ImportWizard *parent);
~EvolutionCalendar();
};
......
......@@ -17,6 +17,7 @@
#include "evolutionv3importdata.h"
#include "evolutionsettings.h"
#include "evolutioncalendar.h"
#include "mailimporter/filter_evolution_v3.h"
#include "mailimporter/filterinfo.h"
#include "importfilterinfogui.h"
......@@ -94,6 +95,17 @@ bool Evolutionv3ImportData::importAddressBook()
return false;
}
bool Evolutionv3ImportData::importCalendar()
{
const QString calendarFile = QDir::homePath() + QLatin1String("/.gconf/apps/evolution/calendar/%gconf.xml");
if ( QFile( calendarFile ).exists() ) {
EvolutionCalendar calendar( calendarFile, mImportWizard );
return true;
}
return false;
}
AbstractImporter::TypeSupportedOptions Evolutionv3ImportData::supportedOption()
{
TypeSupportedOptions options;
......
......@@ -33,6 +33,8 @@ public:
bool importMails();
bool importFilters();
bool importAddressBook();
bool importCalendar();
QString name() const;
};
......
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