summaryrefslogtreecommitdiffabout
path: root/kmicromail/libmailwrapper/settings.cpp
Side-by-side diff
Diffstat (limited to 'kmicromail/libmailwrapper/settings.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kmicromail/libmailwrapper/settings.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/kmicromail/libmailwrapper/settings.cpp b/kmicromail/libmailwrapper/settings.cpp
index 90e32fa..f996d9c 100644
--- a/kmicromail/libmailwrapper/settings.cpp
+++ b/kmicromail/libmailwrapper/settings.cpp
@@ -176,8 +176,14 @@ void IMAPaccount::read()
if (password.isNull()) password = "";
prefix = conf->readEntry("MailPrefix","");
if (prefix.isNull()) prefix = "";
offline = conf->readBoolEntry("Offline",false);
+ localFolder = conf->readEntry( "LocalFolder" );
+ maxMailSize = conf->readNumEntry( "MaxSize",0 );
+ int lf = conf->readNumEntry( "LastFetch",0 );
+ QDateTime dt ( QDate ( 2004, 1, 1 ), QTime( 0,0,0) );
+ leaveOnServer = conf->readBoolEntry("LeaveOnServer",false);
+ lastFetch = dt.addSecs( lf );
delete conf;
}
void IMAPaccount::save()
@@ -195,8 +201,14 @@ void IMAPaccount::save()
conf->writeEntry( "User", user );
conf->writeEntryCrypt( "Password", password );
conf->writeEntry( "MailPrefix",prefix);
conf->writeEntry( "Offline",offline);
+ conf->writeEntry( "LocalFolder", localFolder );
+ conf->writeEntry( "MaxSize", maxMailSize );
+ QDateTime dt ( QDate ( 2004, 1, 1 ), QTime( 0,0,0) );
+ int lf = dt.secsTo ( lastFetch );
+ conf->writeEntry( "LastFetch", lf );
+ conf->writeEntry( "LeaveOnServer", leaveOnServer);
conf->write();
delete conf;
}
@@ -258,8 +270,9 @@ void POP3account::read()
localFolder = conf->readEntry( "LocalFolder" );
maxMailSize = conf->readNumEntry( "MaxSize",0 );
int lf = conf->readNumEntry( "LastFetch",0 );
QDateTime dt ( QDate ( 2004, 1, 1 ), QTime( 0,0,0) );
+ leaveOnServer = conf->readBoolEntry("LeaveOnServer",false);
lastFetch = dt.addSecs( lf );
delete conf;
}
@@ -281,8 +294,9 @@ void POP3account::save()
conf->writeEntry( "MaxSize", maxMailSize );
QDateTime dt ( QDate ( 2004, 1, 1 ), QTime( 0,0,0) );
int lf = dt.secsTo ( lastFetch );
conf->writeEntry( "LastFetch", lf );
+ conf->writeEntry( "LeaveOnServer", leaveOnServer);
conf->write();
delete conf;
}