author | zautrix <zautrix> | 2005-07-26 14:26:36 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-07-26 14:26:36 (UTC) |
commit | e1d72bb77c51ff7313b390f263bc1f10d20123b0 (patch) (unidiff) | |
tree | 35f6cb7936a6e05914bdb9329ece3143c8c9a2f7 | |
parent | 08f8edb64a919e51ad6e1a62031569a629cffa0f (diff) | |
download | kdepimpi-e1d72bb77c51ff7313b390f263bc1f10d20123b0.zip kdepimpi-e1d72bb77c51ff7313b390f263bc1f10d20123b0.tar.gz kdepimpi-e1d72bb77c51ff7313b390f263bc1f10d20123b0.tar.bz2 |
fixx
-rw-r--r-- | korganizer/calendarview.cpp | 7 | ||||
-rw-r--r-- | korganizer/kofilterview.cpp | 10 |
2 files changed, 11 insertions, 6 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 9674921..3ab4bb4 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -738,17 +738,17 @@ void CalendarView::nextConflict( bool all, bool allday ) | |||
738 | int hour = conflict.time().hour(); | 738 | int hour = conflict.time().hour(); |
739 | mViewManager->agendaView()->setStartHour( hour ); | 739 | mViewManager->agendaView()->setStartHour( hour ); |
740 | topLevelWidget()->setCaption( i18n("Conflict %1 <-> %2"). arg( cE->summary().left( 20 ) ).arg( cE2->summary().left( 20 ) ) ); | 740 | topLevelWidget()->setCaption( i18n("Conflict %1 <-> %2"). arg( cE->summary().left( 20 ) ).arg( cE2->summary().left( 20 ) ) ); |
741 | block = false; | 741 | block = false; |
742 | return; | 742 | return; |
743 | } | 743 | } |
744 | 744 | ||
745 | topLevelWidget()->setCaption( i18n("No conflict found") ); | 745 | topLevelWidget()->setCaption( i18n("No conflict found") ); |
746 | qDebug("No conflict found "); | 746 | //qDebug("No conflict found "); |
747 | block = false; | 747 | block = false; |
748 | return; | 748 | return; |
749 | } | 749 | } |
750 | 750 | ||
751 | void CalendarView::conflictAll() | 751 | void CalendarView::conflictAll() |
752 | { | 752 | { |
753 | nextConflict ( true, true ); | 753 | nextConflict ( true, true ); |
754 | } | 754 | } |
@@ -2823,24 +2823,25 @@ void CalendarView::checkConflictForEvent() | |||
2823 | cE = test; | 2823 | cE = test; |
2824 | } | 2824 | } |
2825 | } | 2825 | } |
2826 | found = true; | 2826 | found = true; |
2827 | } | 2827 | } |
2828 | } | 2828 | } |
2829 | test = testlist.next(); | 2829 | test = testlist.next(); |
2830 | } | 2830 | } |
2831 | topLevelWidget()->setCaption( i18n("KO/Pi") ); | ||
2831 | if ( found ) { | 2832 | if ( found ) { |
2832 | QString mess = i18n("The event\n%1\nconflicts with event\n%2\nat date\n%3.\n").arg(KGlobal::formatMessage ( mConflictingEvent->summary(),0 ) ).arg( KGlobal::formatMessage ( cE->summary(),0 )).arg(KGlobal::locale()->formatDate(conflict.date()) ) ; | 2833 | QString mess = i18n("The event\n%1\nconflicts with event\n%2\nat date\n%3.\n").arg(KGlobal::formatMessage ( mConflictingEvent->summary(),0 ) ).arg( KGlobal::formatMessage ( cE->summary(),0 )).arg(KGlobal::locale()->formatDate(conflict.date()) ) ; |
2833 | qApp->processEvents(); | 2834 | qApp->processEvents(); |
2834 | int km = KMessageBox::warningContinueCancel(this,mess, | 2835 | int km = KMessageBox::warningContinueCancel(this,mess, |
2835 | i18n("KO/Pi Conflict delected"),i18n("Show date"),i18n("No problem!")); | 2836 | i18n("KO/Pi Conflict delected"),i18n("Show date"),i18n("No problem!")); |
2836 | if ( km != KMessageBox::Continue ) | 2837 | if ( km != KMessageBox::Continue ) { |
2837 | return; | 2838 | return; |
2838 | 2839 | } | |
2839 | if ( mViewManager->currentView() != mViewManager->agendaView() || mNavigator->selectedDates().count() > 1 ) | 2840 | if ( mViewManager->currentView() != mViewManager->agendaView() || mNavigator->selectedDates().count() > 1 ) |
2840 | mViewManager->showDayView(); | 2841 | mViewManager->showDayView(); |
2841 | mNavigator->slotDaySelect( conflict.date() ); | 2842 | mNavigator->slotDaySelect( conflict.date() ); |
2842 | int hour = conflict.time().hour(); | 2843 | int hour = conflict.time().hour(); |
2843 | mViewManager->agendaView()->setStartHour( hour ); | 2844 | mViewManager->agendaView()->setStartHour( hour ); |
2844 | topLevelWidget()->setCaption( i18n("Conflict %1 <-> %2"). arg( mConflictingEvent->summary().left( 20 ) ).arg( cE->summary().left( 20 ) ) ); | 2845 | topLevelWidget()->setCaption( i18n("Conflict %1 <-> %2"). arg( mConflictingEvent->summary().left( 20 ) ).arg( cE->summary().left( 20 ) ) ); |
2845 | } else | 2846 | } else |
2846 | topLevelWidget()->setCaption( i18n("No conflict found") ); | 2847 | topLevelWidget()->setCaption( i18n("No conflict found") ); |
diff --git a/korganizer/kofilterview.cpp b/korganizer/kofilterview.cpp index 7ce3f1f..6a6fff9 100644 --- a/korganizer/kofilterview.cpp +++ b/korganizer/kofilterview.cpp | |||
@@ -360,17 +360,17 @@ void KOCalEditView::readConfig() | |||
360 | 360 | ||
361 | void KOCalEditView::defaultInfo() | 361 | void KOCalEditView::defaultInfo() |
362 | { | 362 | { |
363 | KMessageBox::information( this, i18n("Please choose the <b>default calendar</b> in this column. Newly created or imported items are added to the default calendar.") ); | 363 | KMessageBox::information( this, i18n("Please choose the <b>default calendar</b> in this column. Newly created or imported items are added to the default calendar.") ); |
364 | } | 364 | } |
365 | void KOCalEditView::addCal() | 365 | void KOCalEditView::addCal() |
366 | { | 366 | { |
367 | bool tryagain = true; | 367 | bool tryagain = true; |
368 | QString name, file; | 368 | QString name, file = KGlobalSettings::calendarDir()+"newCal.ics"; |
369 | while ( tryagain ) { | 369 | while ( tryagain ) { |
370 | KONewCalPrefs prefs ( this ); | 370 | KONewCalPrefs prefs ( this ); |
371 | prefs.nameE->setText( name ); | 371 | prefs.nameE->setText( name ); |
372 | prefs.url->setURL( file ); | 372 | prefs.url->setURL( file ); |
373 | if ( ! prefs.exec() ) | 373 | if ( ! prefs.exec() ) |
374 | return; | 374 | return; |
375 | name = prefs.calName(); | 375 | name = prefs.calName(); |
376 | file = prefs.calFileName(); | 376 | file = prefs.calFileName(); |
@@ -381,24 +381,28 @@ void KOCalEditView::addCal() | |||
381 | KMessageBox::information( this, i18n("Sorry, the calendar name \n%1\nalready exists!\nPlease choose another name!").arg( name ) ); | 381 | KMessageBox::information( this, i18n("Sorry, the calendar name \n%1\nalready exists!\nPlease choose another name!").arg( name ) ); |
382 | name = ""; | 382 | name = ""; |
383 | tryagain = true; | 383 | tryagain = true; |
384 | break; | 384 | break; |
385 | } | 385 | } |
386 | if ( kkf->mFileName == file ) { | 386 | if ( kkf->mFileName == file ) { |
387 | KMessageBox::information( this, i18n("Sorry, the file \n%1\nis already loaded!\nPlease choose another file!").arg( KGlobal::formatMessage (file, 0 )) ); | 387 | KMessageBox::information( this, i18n("Sorry, the file \n%1\nis already loaded!\nPlease choose another file!").arg( KGlobal::formatMessage (file, 0 )) ); |
388 | tryagain = true; | 388 | tryagain = true; |
389 | file = ""; | 389 | file = KGlobalSettings::calendarDir()+"newCal.ics"; |
390 | break; | 390 | break; |
391 | } | 391 | } |
392 | kkf = KOPrefs::instance()->mCalendars.next(); | 392 | kkf = KOPrefs::instance()->mCalendars.next(); |
393 | } | ||
394 | QFileInfo fi ( file ); | ||
395 | if ( fi.isDir() ) { | ||
396 | tryagain = true; | ||
393 | } | 397 | } |
394 | } | 398 | } |
395 | addCalendar ( name, file ); | 399 | addCalendar ( name, file ); |
396 | QTimer::singleShot( 100, this, SIGNAL ( checkCalendar() ) ); | 400 | QTimer::singleShot( 100, this, SIGNAL ( checkCalendar() ) ); |
397 | } | 401 | } |
398 | int KOCalEditView::addCalendar( QString name, QString file, bool ask ) | 402 | int KOCalEditView::addCalendar( QString name, QString file, bool ask ) |
399 | { | 403 | { |
400 | 404 | ||
401 | QFileInfo fi ( file ); | 405 | QFileInfo fi ( file ); |
402 | QString absFile = file; | 406 | QString absFile = file; |
403 | bool isRelative = false; | 407 | bool isRelative = false; |
404 | if ( fi.isRelative() ) { | 408 | if ( fi.isRelative() ) { |