From c53efbe8f53f468d21d93f5e19b625d1a4beb242 Mon Sep 17 00:00:00 2001 From: zautrix Date: Fri, 01 Jul 2005 18:39:59 +0000 Subject: fixxx --- (limited to 'korganizer/calendarview.cpp') diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 70a1d2d..678143d 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp @@ -474,6 +474,7 @@ void CalendarView::init() connect( mCalEditView, SIGNAL( removeCalendar(int) ),mCalendar, SLOT( setCalendarRemove(int)) ); connect( mCalEditView, SIGNAL( calendarAdded(int) ),this, SLOT( addCalendarId(int)) ); connect( mCalEditView, SIGNAL( needsUpdate() ),this, SLOT( updateView()) ); + connect( mCalEditView, SIGNAL( checkCalendar() ),this, SLOT( checkFiles() )); connect( mCalEditView, SIGNAL( needsUpdate() ),this, SLOT( updateUnmanagedViews()) ); mTodoList->setNavigator( mNavigator ); @@ -681,10 +682,8 @@ void CalendarView::scrollBarValue(int val ) #endif } - -void CalendarView::checkAlarms() +void CalendarView::checkFiles() { - QString message; QPtrList calendars = KOPrefs::instance()->mCalendars; KopiCalendarFile * cal = calendars.first(); @@ -695,9 +694,15 @@ void CalendarView::checkAlarms() cal = calendars.next(); } if ( !message.isEmpty() ) { - message = KGlobal::formatMessage( i18n("The loading of one or more calendar failed:"),0 )+"\n" + message +KGlobal::formatMessage(i18n("You can try to reload the calendar in the Resource View!"),0); - KMessageBox::error(this,message); + message = KGlobal::formatMessage( i18n("Calendar(s) not loaded:"),0 )+"\n" + message +KGlobal::formatMessage(i18n("You can try to reload the calendar in the Resource View!"),0); + KMessageBox::error(this,message, i18n("Loding of calendar(s) failed")); } + QTimer::singleShot( 2000, this, SLOT ( checkAlarms() )); +} +void CalendarView::checkAlarms() +{ + + KConfig *config = KOGlobals::config(); config->setGroup( "AppRun" ); QDateTime dt ( QDate (2005,1,1), QTime( 0,0,0 ) ); -- cgit v0.9.0.2