author | zautrix <zautrix> | 2005-11-25 20:49:16 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-11-25 20:49:16 (UTC) |
commit | 2468bddcb380d8621d5bb49b69b3492d90562d93 (patch) (side-by-side diff) | |
tree | c310f4fff5e476087e8406614e57a7f258f1b14f /libkdepim | |
parent | 7a439999b9fa2bd7ad76e195cdf95bf5211952cb (diff) | |
download | kdepimpi-2468bddcb380d8621d5bb49b69b3492d90562d93.zip kdepimpi-2468bddcb380d8621d5bb49b69b3492d90562d93.tar.gz kdepimpi-2468bddcb380d8621d5bb49b69b3492d90562d93.tar.bz2 |
sync
-rw-r--r-- | libkdepim/ksyncmanager.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libkdepim/ksyncmanager.cpp b/libkdepim/ksyncmanager.cpp index 795cd30..d2cb71b 100644 --- a/libkdepim/ksyncmanager.cpp +++ b/libkdepim/ksyncmanager.cpp @@ -1119,67 +1119,66 @@ QString KSyncManager::syncFileName() return (QString( "/tmp/" )+ fn ); #endif } void KSyncManager::syncPi() { mIsKapiFile = true; mPisyncFinished = false; qApp->processEvents(); if ( mAskForPreferences ) if ( !edit_pisync_options()) { mParent->topLevelWidget()->setCaption( i18n("Syncing aborted. Nothing synced.") ); mPisyncFinished = true; return; } bool ok; Q_UINT16 port = mActiveSyncPort.toUInt(&ok); if ( ! ok ) { mParent->topLevelWidget()->setCaption( i18n("Sorry, no valid port.Syncing cancelled.") ); mPisyncFinished = true; return; } mCurrentResourceLocal = ""; mCurrentResourceRemote = ""; - qDebug ( "KSM: sync pi %d",mSpecificResources.count() ); if ( mSpecificResources.count() ) { int lastSyncRes = mSpecificResources.count()/2; int ccc = mSpecificResources.count()-1; while ( lastSyncRes > 0 && ccc > 0 && mSpecificResources[ ccc ].isEmpty() ) { --ccc; --lastSyncRes; - qDebug ( "KSM: sync pi %d",ccc ); + //qDebug ( "KSM: sync pi %d",ccc ); } int startLocal = 0; int startRemote = mSpecificResources.count()/2; emit multiResourceSyncStart( true ); while ( startLocal < mSpecificResources.count()/2 ) { if ( startLocal+1 >= lastSyncRes ) emit multiResourceSyncStart( false ); mPisyncFinished = false; mCurrentResourceLocal = mSpecificResources[ startLocal ]; mCurrentResourceRemote = mSpecificResources[ startRemote ]; - qDebug ( "KSM: AAASyncing resources: Local: %s --- Remote: %s ",mCurrentResourceLocal.latin1(), mCurrentResourceRemote.latin1() ); + //qDebug ( "KSM: AAASyncing resources: Local: %s --- Remote: %s ",mCurrentResourceLocal.latin1(), mCurrentResourceRemote.latin1() ); if ( !mCurrentResourceRemote.isEmpty() ) { qDebug ( "KSM: Syncing resources: Local: %s --- Remote: %s ",mCurrentResourceLocal.latin1(), mCurrentResourceRemote.latin1() ); KCommandSocket* commandSocket = new KCommandSocket( mCurrentResourceRemote, mPassWordPiSync, port, mActiveSyncIP, this, mParent->topLevelWidget() ); connect( commandSocket, SIGNAL(commandFinished( KCommandSocket*, int )), this, SLOT(deleteCommandSocket(KCommandSocket*, int)) ); commandSocket->readFile( syncFileName() ); while ( !mPisyncFinished ) { //qDebug("waiting "); qApp->processEvents(); } } ++startRemote; ++startLocal; } mPisyncFinished = true; } else { KCommandSocket* commandSocket = new KCommandSocket( "", mPassWordPiSync, port, mActiveSyncIP, this, mParent->topLevelWidget() ); connect( commandSocket, SIGNAL(commandFinished( KCommandSocket*, int )), this, SLOT(deleteCommandSocket(KCommandSocket*, int)) ); commandSocket->readFile( syncFileName() ); } } void KSyncManager::deleteCommandSocket(KCommandSocket*s, int state) { //enum { success, errorW, errorR, quiet }; |