author | zautrix <zautrix> | 2005-02-09 19:31:50 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-02-09 19:31:50 (UTC) |
commit | a9eff860d8399a198a9fdc04e09ed369097fc745 (patch) (side-by-side diff) | |
tree | c953f38ef75bed96bdedd61b1b4bf369e08cddee | |
parent | 22d5db839c9741cb2e988e84bbb367617934ebd9 (diff) | |
download | kdepimpi-a9eff860d8399a198a9fdc04e09ed369097fc745.zip kdepimpi-a9eff860d8399a198a9fdc04e09ed369097fc745.tar.gz kdepimpi-a9eff860d8399a198a9fdc04e09ed369097fc745.tar.bz2 |
fixes
-rw-r--r-- | bin/kdepim/WhatsNew.txt | 9 | ||||
-rw-r--r-- | korganizer/mainwindow.cpp | 18 | ||||
-rw-r--r-- | korganizer/mainwindow.h | 1 | ||||
-rw-r--r-- | libkdepim/ksyncmanager.cpp | 13 | ||||
-rw-r--r-- | libkdepim/ksyncmanager.h | 2 |
5 files changed, 34 insertions, 9 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt index 65bb075..6ccf763 100644 --- a/bin/kdepim/WhatsNew.txt +++ b/bin/kdepim/WhatsNew.txt @@ -1,10 +1,19 @@ Info about the changes in new versions of KDE-Pim/Pi +********** VERSION 2.0.6 ************ + +Two bugfixes in the pi-sync mode. +KO/Pi: +Made the todolist using alternate background. + +Other minor fixes in KO/Pi. + + ********** VERSION 2.0.5 ************ Bugfixes in KO/Pi. ********** VERSION 2.0.4 ************ KO/Pi: Fixed problem loading translations for summary/location edit boxes in event/todo editor. diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index 468fd5b..18a4b12 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp @@ -260,17 +260,17 @@ MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) : //fillSyncMenu(); connect(mSyncManager , SIGNAL( save() ), this, SLOT( save() ) ); connect(mView , SIGNAL( save() ), this, SLOT( save() ) ); connect(mView , SIGNAL( saveStopTimer() ), this, SLOT( saveStopTimer() ) ); connect(mSyncManager , SIGNAL( request_file() ), this, SLOT( syncFileRequest() ) ); connect(mSyncManager , SIGNAL( getFile( bool )), this, SLOT(getFile( bool ) ) ); - mSyncManager->setDefaultFileName( defaultFileName()); + mSyncManager->setDefaultFileName( sentSyncFile()); connect ( syncMenu, SIGNAL( activated ( int ) ), mSyncManager, SLOT (slotSyncMenu( int ) ) ); mSyncManager->fillSyncMenu(); mView->viewManager()->agendaView()->setStartHour( KOPrefs::instance()->mDayBegins ); if ( showWarning ) { KMessageBox::information( this, @@ -1987,31 +1987,43 @@ void MainWindow::exportVCalendar() mes = i18n("KO/Pi:Exported to ...%1").arg(fn.right(20)) ; else mes = i18n("KO/Pi:Exported to %1").arg(fn ); setCaption(mes); } } } +QString MainWindow::sentSyncFile() +{ +#ifdef DESKTOP_VERSION + return locateLocal( "tmp", "copysynccal.ics" ); +#else + return QString( "/tmp/copysynccal.ics" ); +#endif +} void MainWindow::syncFileRequest() { if ( KOPrefs::instance()->mPassiveSyncWithDesktop ) { mSyncManager->slotSyncMenu( 999 ); } - save(); + + setCaption(i18n("Saving Data to temp file ..." )); + mView->saveCalendar( sentSyncFile() ); + setCaption(i18n("Data saved to temp file!" )); + } void MainWindow::getFile( bool success ) { if ( ! success ) { setCaption( i18n("Error receiving file. Nothing changed!") ); return; } - mView->openCalendar( defaultFileName() ); + mView->openCalendar( sentSyncFile() ); if ( KOPrefs::instance()->mPassiveSyncWithDesktop ) { mSyncManager->slotSyncMenu( 999 ); } setCaption( i18n("Pi-Sync successful!") ); } void MainWindow::printSel( ) { diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h index 5b9f903..5808700 100644 --- a/korganizer/mainwindow.h +++ b/korganizer/mainwindow.h @@ -98,16 +98,17 @@ class MainWindow : public QMainWindow signals: void selectWeek ( int ); private slots: void showConfigureAgenda(); void getFile( bool ); void syncFileRequest(); protected: + QString sentSyncFile(); void displayText( QString, QString); void enableIncidenceActions( bool ); private: bool mBRdisabled; #ifndef DESKTOP_VERSION QCopChannel* infrared; #endif diff --git a/libkdepim/ksyncmanager.cpp b/libkdepim/ksyncmanager.cpp index 9177f63..c8d0e0d 100644 --- a/libkdepim/ksyncmanager.cpp +++ b/libkdepim/ksyncmanager.cpp @@ -67,26 +67,30 @@ KSyncManager::KSyncManager(QWidget* parent, KSyncInterface* implementation, Targ mWriteBackInPast = 2; int w = 300; if ( QApplication::desktop()->width() < 320 ) w = 220; int h = bar->sizeHint().height() ; int dw = QApplication::desktop()->width(); int dh = QApplication::desktop()->height(); bar->setGeometry( (dw-w)/2, (dh - h )/2 ,w,h ); - if ( mPrefs->mPassiveSyncAutoStart ) - enableQuick( false ); } KSyncManager::~KSyncManager() { delete bar; } - + +void KSyncManager::setDefaultFileName( QString s) +{ + mDefFileName = s ; + if ( mPrefs->mPassiveSyncAutoStart ) + enableQuick( false ); +} void KSyncManager::fillSyncMenu() { if ( mSyncMenu->count() ) mSyncMenu->clear(); mSyncMenu->insertItem( i18n("Configure..."), 0 ); mSyncMenu->insertSeparator(); @@ -407,17 +411,16 @@ void KSyncManager::enableQuick( bool ask ) Q_UINT16 port = mPrefs->mPassiveSyncPort.toUInt(&ok); if ( ! ok ) { KMessageBox::information( 0, i18n("No valid port")); return; } //qDebug("port %d ", port); mServerSocket = new KServerSocket ( mPrefs->mPassiveSyncPw, port ,1 ); mServerSocket->setFileName( defaultFileName() );//bbb - //qDebug("connected "); if ( !mServerSocket->ok() ) { KMessageBox::information( 0, i18n("Failed to bind or\nlisten to the port!")); delete mServerSocket; mServerSocket = 0; return; } mPrefs->mPassiveSyncAutoStart = autoStart; if ( changed ) { @@ -1112,17 +1115,17 @@ void KSyncManager::readFileFromSocket() } KServerSocket:: KServerSocket ( QString pw, Q_UINT16 port, int backlog, QObject * parent, const char * name ) : QServerSocket( port, backlog, parent, name ) { mPassWord = pw; mSocket = 0; mSyncActionDialog = 0; blockRC = false; -}; +} void KServerSocket::newConnection ( int socket ) { // qDebug("KServerSocket:New connection %d ", socket); if ( mSocket ) { qDebug("KSS::newConnection Socket deleted! "); delete mSocket; mSocket = 0; diff --git a/libkdepim/ksyncmanager.h b/libkdepim/ksyncmanager.h index 9a3066e..09bd1c1 100644 --- a/libkdepim/ksyncmanager.h +++ b/libkdepim/ksyncmanager.h @@ -116,17 +116,17 @@ class KSyncManager : public QObject PWMPI = 2 }; KSyncManager(QWidget* parent, KSyncInterface* implementation, TargetApp ta, KPimPrefs* prefs, QPopupMenu* syncmenu); ~KSyncManager() ; void multiSync( bool askforPrefs ); bool blockSave() { return mBlockSaveFlag; } void setBlockSave(bool sa) { mBlockSaveFlag = sa; } - void setDefaultFileName( QString s) { mDefFileName = s ;} + void setDefaultFileName( QString s) ; QString defaultFileName() { return mDefFileName ;} QString syncFileName(); void enableQuick( bool ask = true); bool syncWithDesktop () { return mSyncWithDesktop;} QString getCurrentSyncDevice() { return mCurrentSyncDevice; } QString getCurrentSyncName() { return mCurrentSyncName; } |