Skip to content

Commit

Permalink
Move syncCacheDir implementation to single instance
Browse files Browse the repository at this point in the history
  • Loading branch information
pvuorela committed Apr 7, 2021
1 parent 693dd17 commit a9d490c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 1 addition & 7 deletions libbuteosyncfw/common/SyncCommonDefs.h
Expand Up @@ -31,13 +31,7 @@

namespace Sync {

#ifdef __GNUC__
static const QString syncCacheDir() __attribute__ ((unused));
#endif
static const QString syncCacheDir()
{
return QStandardPaths::writableLocation(QStandardPaths::GenericCacheLocation) + QDir::separator() + "msyncd";
}
const QString syncCacheDir();

enum SyncStatus {
SYNC_QUEUED = 0,
Expand Down
6 changes: 6 additions & 0 deletions libbuteosyncfw/profile/ProfileManager.cpp
Expand Up @@ -35,6 +35,12 @@
#include "LogMacros.h"
#include "BtHelper.h"

// implement here in lack of better place. not sure should this even be included in the api
const QString Sync::syncCacheDir()
{
return QStandardPaths::writableLocation(QStandardPaths::GenericCacheLocation) + QDir::separator() + "msyncd";
}

static const QString FORMAT_EXT = ".xml";
static const QString BACKUP_EXT = ".bak";
static const QString LOG_EXT = ".log";
Expand Down

0 comments on commit a9d490c

Please sign in to comment.