Commit b67977c0 authored by pvuorela's avatar pvuorela

Merge branch 'fix_enum_type' into 'master'

[buteo-sync-plugin-carddav] Use proper enum type. Contributes to JB#31584

See merge request !32
parents 8db37815 beff4d7f
......@@ -58,7 +58,7 @@ void CardDavClient::connectivityStateChanged(Sync::ConnectivityType aType, bool
LOG_DEBUG("Received connectivity change event:" << aType << " changed to " << aState);
if (aType == Sync::CONNECTIVITY_INTERNET && !aState) {
// we lost connectivity during sync.
abortSync(Sync::SYNC_CONNECTION_ERROR);
abortSync(Buteo::SyncResults::CONNECTION_ERROR);
}
}
......@@ -112,20 +112,14 @@ void CardDavClient::syncFailed()
syncFinished(Buteo::SyncResults::INTERNAL_ERROR, QString());
}
void CardDavClient::abortSync(Sync::SyncStatus aStatus)
{
FUNCTION_CALL_TRACE;
abort(aStatus);
}
void CardDavClient::abort(Sync::SyncStatus status)
void CardDavClient::abortSync(Buteo::SyncResults::MinorCode code)
{
FUNCTION_CALL_TRACE;
m_syncer->abortSync();
syncFinished(status, QStringLiteral("Sync aborted"));
syncFinished(code, QStringLiteral("Sync aborted"));
}
void CardDavClient::syncFinished(int minorErrorCode, const QString &message)
void CardDavClient::syncFinished(Buteo::SyncResults::MinorCode minorErrorCode, const QString &message)
{
FUNCTION_CALL_TRACE;
......
......@@ -46,7 +46,6 @@ public:
bool init();
bool uninit();
bool startSync();
void abortSync(Sync::SyncStatus aStatus = Sync::SYNC_ABORTED);
Buteo::SyncResults getSyncResults() const;
bool cleanUp();
......@@ -58,8 +57,8 @@ private Q_SLOTS:
void syncFailed();
private:
void abort(Sync::SyncStatus aStatus = Sync::SYNC_ABORTED);
void syncFinished(int minorErrorCode, const QString &message);
void abortSync(Buteo::SyncResults::MinorCode code);
void syncFinished(Buteo::SyncResults::MinorCode minorErrorCode, const QString &message);
Buteo::SyncProfile::SyncDirection syncDirection();
Buteo::SyncProfile::ConflictResolutionPolicy conflictResolutionPolicy();
......
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