Skip to content
Snippets Groups Projects
Commit 1facaff2 authored by Adrien Béraud's avatar Adrien Béraud
Browse files

account: allow to set ArchivePath

Setting the archive path is used to optionally add a Ring account from
an existing archive (export.gz) file.

Change-Id: I2d3b3b62b07b8544e1ffce6086e3bdd351b6e619
parent e8748420
Branches
No related tags found
No related merge requests found
...@@ -1101,6 +1101,11 @@ QString Account::archivePin() const ...@@ -1101,6 +1101,11 @@ QString Account::archivePin() const
return d_ptr->accountDetail(DRing::Account::ConfProperties::ARCHIVE_PIN); return d_ptr->accountDetail(DRing::Account::ConfProperties::ARCHIVE_PIN);
} }
QString Account::archivePath() const
{
return d_ptr->accountDetail(DRing::Account::ConfProperties::ARCHIVE_PATH);
}
bool Account::allowIncomingFromUnknown() const bool Account::allowIncomingFromUnknown() const
{ {
return d_ptr->accountDetail(DRing::Account::ConfProperties::DHT::PUBLIC_IN_CALLS) IS_TRUE; return d_ptr->accountDetail(DRing::Account::ConfProperties::DHT::PUBLIC_IN_CALLS) IS_TRUE;
...@@ -2014,6 +2019,11 @@ void Account::setArchivePin(const QString& value) ...@@ -2014,6 +2019,11 @@ void Account::setArchivePin(const QString& value)
d_ptr->setAccountProperty(DRing::Account::ConfProperties::ARCHIVE_PIN, value); d_ptr->setAccountProperty(DRing::Account::ConfProperties::ARCHIVE_PIN, value);
} }
void Account::setArchivePath(const QString& value)
{
d_ptr->setAccountProperty(DRing::Account::ConfProperties::ARCHIVE_PATH, value);
}
void Account::setAllowIncomingFromUnknown(bool value) void Account::setAllowIncomingFromUnknown(bool value)
{ {
d_ptr->setAccountProperty(DRing::Account::ConfProperties::DHT::PUBLIC_IN_CALLS, (value)TO_BOOL); d_ptr->setAccountProperty(DRing::Account::ConfProperties::DHT::PUBLIC_IN_CALLS, (value)TO_BOOL);
......
...@@ -143,6 +143,7 @@ class LIB_EXPORT Account : public ItemBase { ...@@ -143,6 +143,7 @@ class LIB_EXPORT Account : public ItemBase {
Q_PROPERTY(QString displayName READ displayName WRITE setDisplayName ) Q_PROPERTY(QString displayName READ displayName WRITE setDisplayName )
Q_PROPERTY(QString archivePassword READ archivePassword WRITE setArchivePassword ) Q_PROPERTY(QString archivePassword READ archivePassword WRITE setArchivePassword )
Q_PROPERTY(QString archivePin READ archivePin WRITE setArchivePin ) Q_PROPERTY(QString archivePin READ archivePin WRITE setArchivePin )
Q_PROPERTY(QString archivePath READ archivePath WRITE setArchivePath )
Q_PROPERTY(RegistrationState registrationState READ registrationState WRITE setRegistrationState ) Q_PROPERTY(RegistrationState registrationState READ registrationState WRITE setRegistrationState )
Q_PROPERTY(bool usedForOutgogingCall READ isUsedForOutgogingCall ) Q_PROPERTY(bool usedForOutgogingCall READ isUsedForOutgogingCall )
Q_PROPERTY(uint totalCallCount READ totalCallCount ) Q_PROPERTY(uint totalCallCount READ totalCallCount )
...@@ -449,6 +450,7 @@ class LIB_EXPORT Account : public ItemBase { ...@@ -449,6 +450,7 @@ class LIB_EXPORT Account : public ItemBase {
QString displayName () const; QString displayName () const;
QString archivePassword () const; QString archivePassword () const;
QString archivePin () const; QString archivePin () const;
QString archivePath () const;
RegistrationState registrationState () const; RegistrationState registrationState () const;
Protocol protocol () const; Protocol protocol () const;
ContactMethod* contactMethod () const; ContactMethod* contactMethod () const;
...@@ -519,6 +521,7 @@ class LIB_EXPORT Account : public ItemBase { ...@@ -519,6 +521,7 @@ class LIB_EXPORT Account : public ItemBase {
void setDisplayName (const QString& value ); void setDisplayName (const QString& value );
void setArchivePassword (const QString& value ); void setArchivePassword (const QString& value );
void setArchivePin (const QString& value ); void setArchivePin (const QString& value );
void setArchivePath (const QString& value );
void setVoiceMailCount (int count ); void setVoiceMailCount (int count );
void setRegistrationExpire (int detail); void setRegistrationExpire (int detail);
void setTlsNegotiationTimeoutSec (int detail); void setTlsNegotiationTimeoutSec (int detail);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment