summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2005-02-03 00:01:07 (UTC)
committer zautrix <zautrix>2005-02-03 00:01:07 (UTC)
commitca3c58c09b1b7d2733eeacc9e8ca568134926e93 (patch) (unidiff)
treedbee3bfe638d1ae44288ae6c209e014e40206c0d /korganizer
parent279354f19275e5e654636acb87c465edf652eeae (diff)
downloadkdepimpi-ca3c58c09b1b7d2733eeacc9e8ca568134926e93.zip
kdepimpi-ca3c58c09b1b7d2733eeacc9e8ca568134926e93.tar.gz
kdepimpi-ca3c58c09b1b7d2733eeacc9e8ca568134926e93.tar.bz2
tz fixes
Diffstat (limited to 'korganizer') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/calendarview.cpp18
-rw-r--r--korganizer/calendarview.h2
-rw-r--r--korganizer/mainwindow.cpp19
-rw-r--r--korganizer/mainwindow.h1
4 files changed, 36 insertions, 4 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index e0380fa..77de94f 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -2253,4 +2253,20 @@ void CalendarView::edit_options()
2253{ 2253{
2254 QString tz = KPimGlobalPrefs::instance()->mTimeZoneId;
2255 emit save();
2256 emit saveStopTimer();
2254 mDialogManager->showOptionsDialog(); 2257 mDialogManager->showOptionsDialog();
2255 //writeSettings(); 2258 if ( tz != KPimGlobalPrefs::instance()->mTimeZoneId) {
2259 emit saveStopTimer();
2260 if ( KMessageBox::Cancel == KMessageBox::warningContinueCancel(this, i18n("The timezone has changed!\nShould the calendar be reloaded\nto apply timezone changes?\nPlease read Menu: Help->FAQ:\n\"How do I change the timezone?\"\nas well!"),
2261 i18n("Timezone settings"),i18n("Reload"))) {
2262 qDebug("KO: TZ reload cancelled ");
2263 return;
2264 }
2265 qDebug("KO: Timezone change ");
2266 openCalendar( MainWindow::defaultFileName() );
2267 setModified(true);
2268 }
2269 else
2270 qDebug("KO: No tz change ");
2271
2256} 2272}
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h
index 6ea8287..8d7ff36 100644
--- a/korganizer/calendarview.h
+++ b/korganizer/calendarview.h
@@ -119,2 +119,4 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser
119 signals: 119 signals:
120 void save ();
121 void saveStopTimer ();
120 void tempDisableBR(bool); 122 void tempDisableBR(bool);
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index 3feb4ab..a2c20a8 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -261,2 +261,4 @@ MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) :
261 connect(mSyncManager , SIGNAL( save() ), this, SLOT( save() ) ); 261 connect(mSyncManager , SIGNAL( save() ), this, SLOT( save() ) );
262 connect(mView , SIGNAL( save() ), this, SLOT( save() ) );
263 connect(mView , SIGNAL( saveStopTimer() ), this, SLOT( saveStopTimer() ) );
262 connect(mSyncManager , SIGNAL( request_file() ), this, SLOT( syncFileRequest() ) ); 264 connect(mSyncManager , SIGNAL( request_file() ), this, SLOT( syncFileRequest() ) );
@@ -1449,2 +1451,3 @@ void MainWindow::slotModifiedChanged( bool changed )
1449 return; 1451 return;
1452
1450 int msec; 1453 int msec;
@@ -1460,4 +1463,16 @@ void MainWindow::slotModifiedChanged( bool changed )
1460} 1463}
1464void MainWindow::saveStopTimer()
1465{
1466 mSaveTimer.stop();
1467 if (mSaveTimer.isActive() )
1468 qDebug("ti active ");
1469 else
1470 qDebug("KO: Save timer stopped");
1471}
1461void MainWindow::save() 1472void MainWindow::save()
1462{ 1473{
1474 if ( !mCalendarModifiedFlag ) {
1475 qDebug("KO: Calendar not modified. Nothing saved.");
1476 return;
1477 }
1463 if ( mSyncManager->blockSave() ) 1478 if ( mSyncManager->blockSave() )
@@ -1466,3 +1481,2 @@ void MainWindow::save()
1466 if ( mView->checkFileVersion( defaultFileName()) ) { 1481 if ( mView->checkFileVersion( defaultFileName()) ) {
1467
1468 QTime neededSaveTime = QDateTime::currentDateTime().time(); 1482 QTime neededSaveTime = QDateTime::currentDateTime().time();
@@ -1471,3 +1485,3 @@ void MainWindow::save()
1471 mView->saveCalendar( defaultFileName() ); 1485 mView->saveCalendar( defaultFileName() );
1472 1486 mCalendarModifiedFlag = false;
1473 int msNeeded = neededSaveTime.msecsTo( QDateTime::currentDateTime().time() ); 1487 int msNeeded = neededSaveTime.msecsTo( QDateTime::currentDateTime().time() );
@@ -1479,3 +1493,2 @@ void MainWindow::save()
1479 setCaption(i18n("Saving cancelled!")); 1493 setCaption(i18n("Saving cancelled!"));
1480 mCalendarModifiedFlag = false;
1481 mSyncManager->setBlockSave( false ); 1494 mSyncManager->setBlockSave( false );
diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h
index 6de0543..8dd55ac 100644
--- a/korganizer/mainwindow.h
+++ b/korganizer/mainwindow.h
@@ -74,2 +74,3 @@ class MainWindow : public QMainWindow
74 void save(); 74 void save();
75 void saveStopTimer();
75 void configureToolBar( int ); 76 void configureToolBar( int );