-rw-r--r-- | korganizer/mainwindow.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index 3c16458..a69a0bd 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp @@ -314,54 +314,55 @@ void MainWindow::closeEvent( QCloseEvent* ce ) saveOnClose(); mClosed = true; ce->accept(); break; case 1: ce->ignore(); break; case 2: default: break; } } void MainWindow::recieve( const QCString& cmsg, const QByteArray& data ) { QDataStream stream( data, IO_ReadOnly ); // QMessageBox::about( this, "About KOrganizer/Pi", "*" +msg +"*" ); //QString datamess; //qDebug("message "); qDebug("KO: QCOP message received: %s ", cmsg.data() ); - if ( cmsg == "-writeFile" ) { - // I made from the "-writeFile" an "-writeAlarm" - mView->viewManager()->showWhatsNextView(); - mCalendar->checkAlarmForIncidence( 0, true); - showMaximized(); - raise(); + if ( cmsg == "setDocument(QString)" ) { + QDataStream stream( data, IO_ReadOnly ); + QString fileName; + stream >> fileName; + qDebug("filename %s ", fileName.latin1()); + KOPrefs::instance()->mLastSyncedLocalFile = fileName ; + mSyncManager->slotSyncMenu( 1002 ); return; } if ( cmsg == "-writeFile" ) { // I made from the "-writeFile" an "-writeAlarm" mView->viewManager()->showWhatsNextView(); mCalendar->checkAlarmForIncidence( 0, true); showMaximized(); raise(); return; } if ( cmsg == "-writeFileSilent" ) { // I made from the "-writeFile" an "-writeAlarm" // mView->viewManager()->showWhatsNextView(); mCalendar->checkAlarmForIncidence( 0, true); //showMaximized(); //raise(); hide(); return; } if ( cmsg == "-newCountdown" ) { qDebug("newCountdown "); |