-rw-r--r-- | libkdepim/ksyncmanager.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libkdepim/ksyncmanager.cpp b/libkdepim/ksyncmanager.cpp index f80c2a6..e615cbe 100644 --- a/libkdepim/ksyncmanager.cpp +++ b/libkdepim/ksyncmanager.cpp | |||
@@ -1435,65 +1435,65 @@ void KServerSocket::send_file() | |||
1435 | if ( secs > 180 ) | 1435 | if ( secs > 180 ) |
1436 | { | 1436 | { |
1437 | if ( secs > 300 ) { | 1437 | if ( secs > 300 ) { |
1438 | if ( KMessageBox::Cancel == KMessageBox::warningContinueCancel(0, i18n("The clocks of the syncing\ndevices have a difference\nof more than 5 minutes.\nPlease adjust your clocks.\nYou may get wrong syncing results!\nPlease confirm synchronization!"), i18n("High clock skew!"),i18n("Synchronize!"))) { | 1438 | if ( KMessageBox::Cancel == KMessageBox::warningContinueCancel(0, i18n("The clocks of the syncing\ndevices have a difference\nof more than 5 minutes.\nPlease adjust your clocks.\nYou may get wrong syncing results!\nPlease confirm synchronization!"), i18n("High clock skew!"),i18n("Synchronize!"))) { |
1439 | qDebug("KSS::Sync cancelled ,cs"); | 1439 | qDebug("KSS::Sync cancelled ,cs"); |
1440 | mErrorMessage = 0; | 1440 | mErrorMessage = 0; |
1441 | end_connect(); | 1441 | end_connect(); |
1442 | error_connect("ERROR_CA\r\n\r\n"); | 1442 | error_connect("ERROR_CA\r\n\r\n"); |
1443 | return ; | 1443 | return ; |
1444 | } | 1444 | } |
1445 | } | 1445 | } |
1446 | QFont f = label->font(); | 1446 | QFont f = label->font(); |
1447 | f.setPointSize ( f.pointSize() *2 ); | 1447 | f.setPointSize ( f.pointSize() *2 ); |
1448 | f. setBold (true ); | 1448 | f. setBold (true ); |
1449 | QLabel* label = new QLabel( warning, mSyncActionDialog ); | 1449 | QLabel* label = new QLabel( warning, mSyncActionDialog ); |
1450 | label->setFont( f ); | 1450 | label->setFont( f ); |
1451 | warning = i18n("ADJUST\nYOUR\nCLOCKS!"); | 1451 | warning = i18n("ADJUST\nYOUR\nCLOCKS!"); |
1452 | label->setText( warning ); | 1452 | label->setText( warning ); |
1453 | label->setAlignment ( Qt::AlignHCenter ); | 1453 | label->setAlignment ( Qt::AlignHCenter ); |
1454 | lay->addWidget( label); | 1454 | lay->addWidget( label); |
1455 | mSyncActionDialog->setFixedSize( 230, 300); | 1455 | mSyncActionDialog->setFixedSize( 230, 300); |
1456 | } else { | 1456 | } else { |
1457 | mSyncActionDialog->setFixedSize( 230, 200); | 1457 | mSyncActionDialog->setFixedSize( 230, 200); |
1458 | } | 1458 | } |
1459 | } else { | 1459 | } else { |
1460 | mSyncActionDialog->setFixedSize( 230, 120); | 1460 | mSyncActionDialog->setFixedSize( 230, 120); |
1461 | } | 1461 | } |
1462 | } else | 1462 | } else |
1463 | mSyncActionDialog->setFixedSize( 230, 120); | 1463 | mSyncActionDialog->setFixedSize( 230, 120); |
1464 | mSyncActionDialog->show(); | 1464 | mSyncActionDialog->show(); |
1465 | mSyncActionDialog->raise(); | 1465 | mSyncActionDialog->raise(); |
1466 | emit request_file(mResource); | 1466 | emit request_file(mResource); |
1467 | emit request_file(); | 1467 | //emit request_file(); |
1468 | qApp->processEvents(); | 1468 | qApp->processEvents(); |
1469 | QString fileName = mFileName; | 1469 | QString fileName = mFileName; |
1470 | QFile file( fileName ); | 1470 | QFile file( fileName ); |
1471 | if (!file.open( IO_ReadOnly ) ) { | 1471 | if (!file.open( IO_ReadOnly ) ) { |
1472 | mErrorMessage = 0; | 1472 | mErrorMessage = 0; |
1473 | end_connect(); | 1473 | end_connect(); |
1474 | error_connect("ERROR_FI\r\n\r\n"); | 1474 | error_connect("ERROR_FI\r\n\r\n"); |
1475 | return ; | 1475 | return ; |
1476 | } | 1476 | } |
1477 | mSyncActionDialog->setCaption( i18n("Sending file...") ); | 1477 | mSyncActionDialog->setCaption( i18n("Sending file...") ); |
1478 | QTextStream ts( &file ); | 1478 | QTextStream ts( &file ); |
1479 | ts.setEncoding( QTextStream::Latin1 ); | 1479 | ts.setEncoding( QTextStream::Latin1 ); |
1480 | 1480 | ||
1481 | QTextStream os( mSocket ); | 1481 | QTextStream os( mSocket ); |
1482 | os.setEncoding( QTextStream::Latin1 ); | 1482 | os.setEncoding( QTextStream::Latin1 ); |
1483 | while ( ! ts.atEnd() ) { | 1483 | while ( ! ts.atEnd() ) { |
1484 | os << ts.readLine() << "\r\n"; | 1484 | os << ts.readLine() << "\r\n"; |
1485 | } | 1485 | } |
1486 | os << "\r\n"; | 1486 | os << "\r\n"; |
1487 | //os << ts.read(); | 1487 | //os << ts.read(); |
1488 | file.close(); | 1488 | file.close(); |
1489 | mSyncActionDialog->setCaption( i18n("Waiting for synced file...") ); | 1489 | mSyncActionDialog->setCaption( i18n("Waiting for synced file...") ); |
1490 | mSocket->close(); | 1490 | mSocket->close(); |
1491 | if ( mSocket->state() == QSocket::Idle ) | 1491 | if ( mSocket->state() == QSocket::Idle ) |
1492 | QTimer::singleShot( 10, this , SLOT ( discardClient())); | 1492 | QTimer::singleShot( 10, this , SLOT ( discardClient())); |
1493 | } | 1493 | } |
1494 | void KServerSocket::get_file() | 1494 | void KServerSocket::get_file() |
1495 | { | 1495 | { |
1496 | mSyncActionDialog->setCaption( i18n("Receiving synced file...") ); | 1496 | mSyncActionDialog->setCaption( i18n("Receiving synced file...") ); |
1497 | 1497 | ||
1498 | piTime.start(); | 1498 | piTime.start(); |
1499 | piFileString = ""; | 1499 | piFileString = ""; |