summaryrefslogtreecommitdiffabout
path: root/libkdepim/ksyncprefsdialog.cpp
Side-by-side diff
Diffstat (limited to 'libkdepim/ksyncprefsdialog.cpp') (more/less context) (show whitespace changes)
-rw-r--r--libkdepim/ksyncprefsdialog.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/libkdepim/ksyncprefsdialog.cpp b/libkdepim/ksyncprefsdialog.cpp
index cf8f996..03265d2 100644
--- a/libkdepim/ksyncprefsdialog.cpp
+++ b/libkdepim/ksyncprefsdialog.cpp
@@ -241,8 +241,10 @@ void KSyncPrefsDialog::setupSyncAlgTab()
mRemoteFile = new QLineEdit( temphb);
mRemoteFileAB = new QLineEdit( temphb);
mRemoteFilePWM = new QLineEdit( temphb);
+ mIsKapiFileL = new QCheckBox( i18n("Addressbook file (*.vcf) is used by KA/Pi"), localFileWidget );
+
// *** remote
remoteFileWidget = new QVBox( topFrame);
topLayout->addMultiCellWidget(remoteFileWidget, iii,iii,0,1);
@@ -268,9 +270,9 @@ void KSyncPrefsDialog::setupSyncAlgTab()
temphb = new QHBox( remoteFileWidget );
mRemotePostcommand = new QLineEdit(temphb );
mRemotePostcommandAB = new QLineEdit(temphb );
mRemotePostcommandPWM = new QLineEdit(temphb );
-
+ mIsKapiFileR = new QCheckBox( i18n("Addressbook file is used by KA/Pi"), remoteFileWidget );
lab = new QLabel( i18n("Fill in default values for:"), remoteFileWidget);
temphb = new QHBox( remoteFileWidget );
button = new QPushButton( i18n("ssh/scp"), temphb );
connect ( button, SIGNAL( clicked()), this, SLOT (fillSSH() ) );
@@ -456,8 +458,11 @@ void KSyncPrefsDialog::profileChanged( int item )
}
mIsLocal->setChecked(prof->getIsLocalFileSync()) ;
mIsPhone->setChecked(prof->getIsPhoneSync()) ;
mIsPi->setChecked(prof->getIsPiSync()) ;
+ mIsKapiFileL->setChecked(prof->getIsKapiFile()) ;
+ mIsKapiFileR->setChecked(prof->getIsKapiFile()) ;
+
mIsNotLocal->setChecked(!prof->getIsLocalFileSync() && !prof->getIsPhoneSync() &&!prof->getIsPiSync() );
proGr->setEnabled( item > 2 );
if ( item < 3 ) {
localFileWidget->hide();
@@ -497,8 +502,14 @@ void KSyncPrefsDialog::fillFTP()
}
void KSyncPrefsDialog::kindChanged( bool b )
{
+ if ( mIsLocal->isChecked () ) {
+ mIsKapiFileL->setChecked( mIsKapiFileR->isChecked() );
+ } else {
+ mIsKapiFileR->setChecked( mIsKapiFileL->isChecked() );
+ }
+
if ( mIsLocal->isChecked () )
localFileWidget->show();
else
localFileWidget->hide();
@@ -578,8 +589,9 @@ void KSyncPrefsDialog::saveProfile()
prof->setSyncPrefs( syncprefs);
prof->setIsLocalFileSync( mIsLocal->isChecked() );
prof->setIsPhoneSync( mIsPhone->isChecked() );
prof->setIsPiSync( mIsPi->isChecked() );
+ prof->setIsKapiFile( mIsKapiFileL->isChecked() );
prof->setWriteBackFuture(mWriteBackFuture->isChecked());
prof->setWriteBackFutureWeeks(mWriteBackFutureWeeks->value());
if ( mWriteContactToSIM )
prof->setWriteContactToSIM(mWriteContactToSIM->isChecked());