UI: QuotaManager: Save only changed settings.

This commit is contained in:
Nodir Temirkhodjaev 2021-05-09 16:51:08 +03:00
parent 169fcaab56
commit 3200ce71fc

View File

@ -131,8 +131,10 @@ void QuotaManager::setQuotaDayAlerted(qint32 v)
{
m_quotaDayAlerted = v;
ini()->setQuotaDayAlerted(v);
confManager()->saveIni();
if (ini()->quotaDayAlerted() != v) {
ini()->setQuotaDayAlerted(v);
confManager()->saveIni();
}
}
qint32 QuotaManager::quotaMonthAlerted() const
@ -144,6 +146,8 @@ void QuotaManager::setQuotaMonthAlerted(qint32 v)
{
m_quotaMonthAlerted = v;
ini()->setQuotaMonthAlerted(v);
confManager()->saveIni();
if (ini()->quotaMonthAlerted() != v) {
ini()->setQuotaMonthAlerted(v);
confManager()->saveIni();
}
}