summaryrefslogtreecommitdiffabout
path: root/korganizer/calendarview.cpp
Unidiff
Diffstat (limited to 'korganizer/calendarview.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/calendarview.cpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index e0380fa..77de94f 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -2230,50 +2230,66 @@ void CalendarView::edit_copy()
2230 anEvent = static_cast<Event *>(incidence); 2230 anEvent = static_cast<Event *>(incidence);
2231 } 2231 }
2232 } 2232 }
2233 2233
2234 if (!anEvent) { 2234 if (!anEvent) {
2235 KNotifyClient::beep(); 2235 KNotifyClient::beep();
2236 return; 2236 return;
2237 } 2237 }
2238 DndFactory factory( mCalendar ); 2238 DndFactory factory( mCalendar );
2239 factory.copyIncidence(anEvent); 2239 factory.copyIncidence(anEvent);
2240} 2240}
2241 2241
2242void CalendarView::edit_paste() 2242void CalendarView::edit_paste()
2243{ 2243{
2244 QDate date = mNavigator->selectedDates().first(); 2244 QDate date = mNavigator->selectedDates().first();
2245 2245
2246 DndFactory factory( mCalendar ); 2246 DndFactory factory( mCalendar );
2247 Event *pastedEvent = (Event *)factory.pasteIncidence( date ); 2247 Event *pastedEvent = (Event *)factory.pasteIncidence( date );
2248 2248
2249 changeEventDisplay( pastedEvent, KOGlobals::EVENTADDED ); 2249 changeEventDisplay( pastedEvent, KOGlobals::EVENTADDED );
2250} 2250}
2251 2251
2252void CalendarView::edit_options() 2252void 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}
2257 2273
2258 2274
2259void CalendarView::slotSelectPickerDate( QDate d) 2275void CalendarView::slotSelectPickerDate( QDate d)
2260{ 2276{
2261 mDateFrame->hide(); 2277 mDateFrame->hide();
2262 if ( mDatePickerMode == 1 ) { 2278 if ( mDatePickerMode == 1 ) {
2263 mNavigator->slotDaySelect( d ); 2279 mNavigator->slotDaySelect( d );
2264 } else if ( mDatePickerMode == 2 ) { 2280 } else if ( mDatePickerMode == 2 ) {
2265 if ( mMoveIncidence->type() == "Todo" ) { 2281 if ( mMoveIncidence->type() == "Todo" ) {
2266 Todo * to = (Todo *) mMoveIncidence; 2282 Todo * to = (Todo *) mMoveIncidence;
2267 QTime tim; 2283 QTime tim;
2268 if ( to->hasDueDate() ) 2284 if ( to->hasDueDate() )
2269 tim = to->dtDue().time(); 2285 tim = to->dtDue().time();
2270 else { 2286 else {
2271 tim = QTime ( 0,0,0 ); 2287 tim = QTime ( 0,0,0 );
2272 to->setFloats( true ); 2288 to->setFloats( true );
2273 to->setHasDueDate( true ); 2289 to->setHasDueDate( true );
2274 } 2290 }
2275 QDateTime dt ( d,tim ); 2291 QDateTime dt ( d,tim );
2276 to->setDtDue( dt ); 2292 to->setDtDue( dt );
2277 todoChanged( to ); 2293 todoChanged( to );
2278 } else { 2294 } else {
2279 if ( mMoveIncidence->doesRecur() ) { 2295 if ( mMoveIncidence->doesRecur() ) {