mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-02-03 04:39:24 +00:00
feat(src/components/core/CoreManager): log database paths
This commit is contained in:
parent
a17c4ad1ef
commit
5695e8ac6d
1 changed files with 15 additions and 3 deletions
|
|
@ -100,12 +100,24 @@ void CoreManager::forceRefreshRegisters () {
|
|||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
#define SET_DATABASE_PATH(DATABASE, PATH) \
|
||||
do { \
|
||||
qInfo() << QStringLiteral("Set `%1` path: `%2`") \
|
||||
.arg( # DATABASE) \
|
||||
.arg(::Utils::coreStringToAppString(PATH)); \
|
||||
mCore->set ## DATABASE ## DatabasePath(PATH); \
|
||||
} while (0);
|
||||
|
||||
void CoreManager::setDatabasesPaths () {
|
||||
mCore->setFriendsDatabasePath(Paths::getFriendsListFilePath());
|
||||
mCore->setCallLogsDatabasePath(Paths::getCallHistoryFilePath());
|
||||
mCore->setChatDatabasePath(Paths::getMessageHistoryFilePath());
|
||||
SET_DATABASE_PATH(Friends, Paths::getFriendsListFilePath());
|
||||
SET_DATABASE_PATH(CallLogs, Paths::getCallHistoryFilePath());
|
||||
SET_DATABASE_PATH(Chat, Paths::getMessageHistoryFilePath());
|
||||
}
|
||||
|
||||
#undef SET_DATABASE_PATH
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
void CoreManager::setOtherPaths () {
|
||||
if (mCore->getZrtpSecretsFile().empty() || !Paths::filePathExists(mCore->getZrtpSecretsFile())) {
|
||||
mCore->setZrtpSecretsFile(Paths::getZrtpSecretsFilePath());
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue