summaryrefslogtreecommitdiffabout
authorzautrix <zautrix>2005-07-01 18:39:59 (UTC)
committer zautrix <zautrix>2005-07-01 18:39:59 (UTC)
commitc53efbe8f53f468d21d93f5e19b625d1a4beb242 (patch) (side-by-side diff)
treef8fe2180733b6bd3514c02845cefa9f26e967e27
parent98d29d15275c4b8e9a3348742925f6e6d03f7a07 (diff)
downloadkdepimpi-c53efbe8f53f468d21d93f5e19b625d1a4beb242.zip
kdepimpi-c53efbe8f53f468d21d93f5e19b625d1a4beb242.tar.gz
kdepimpi-c53efbe8f53f468d21d93f5e19b625d1a4beb242.tar.bz2
fixxx
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--bin/kdepim/korganizer/germantranslation.txt13
-rw-r--r--korganizer/calendarview.cpp15
-rw-r--r--korganizer/calendarview.h1
-rw-r--r--korganizer/kofilterview.cpp2
-rw-r--r--korganizer/kofilterview.h1
-rw-r--r--korganizer/mainwindow.cpp7
6 files changed, 28 insertions, 11 deletions
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt
index 593806b..708ac19 100644
--- a/bin/kdepim/korganizer/germantranslation.txt
+++ b/bin/kdepim/korganizer/germantranslation.txt
@@ -1469,13 +1469,24 @@
{ "Select Date...","Wähle Datum..." },
{ "After importing/loading/syncing there may be new categories in events or todos which are not added automatically to the category list. Please choose what to do <b>now</b>:","Nach dem Importieren/Laden/Syncen kann es neue Kategorien in den Terminen oder Todos geben, die nicht automatisch der Kategorieliste hinzugefügt werden. Bitte wählen Sie, was <b>jetzt</b> passieren soll:" },
{ "Change category list now!","Ändere Kategorieliste jetzt!" },
{ "Edit category list...","Ändere Kategorieliste..." },
{ "Toolbar changes needs a restart!","Neustart benötigt für Toolbaränderungen!" },
{ "Filepath: ","Dateipfad: " },
-{ "The loading of one or more calendar failed:","Das Laden eines oder mehrerer Kalender schlug fehl:" },
{ "You can try to reload the calendar in the Resource View!","In der Resourcenansicht können Sie erneut versuchen den Kalender zu laden!" },
{ "<b>WARNING:</b> There is a pending suspended alarm!","<b>WARNUNG:</b> Es gibt einen laufenden Suspendalarm!" },
{ "Pending Suspend Alarm","Laufender Suspend Alarm" },
+{ "Error loading calendar %1","Fehler beim Laden von Kalender %1" },
+{ "Calendar(s) not loaded:","Nicht geladene(r) Kalender:" },
+{ "Loding of calendar(s) failed","Laden von Kalendern fehlgeschlagen" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
+{ "","" },
{ "","" },
{ "","" },
{ "","" }, \ No newline at end of file
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 70a1d2d..678143d 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -471,12 +471,13 @@ void CalendarView::init()
connect( mCalEditView, SIGNAL( calendarReadonly(int,bool) ),mCalendar, SLOT( setReadOnly(int,bool)) );
connect( mCalEditView, SIGNAL( setCalendarDefault(int) ),mCalendar, SLOT( setDefaultCalendar(int)) );
connect( mCalEditView, SIGNAL( setCalendarDefault(int) ),mViewManager, SLOT( setDefaultCalendar(int)) );
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 );
#if 0
if ( QApplication::desktop()->width() < 480 ) {
leftFrameLayout->addWidget(mFilterView);
@@ -678,29 +679,33 @@ void CalendarView::scrollBarValue(int val )
QDate d ( year,1,1 );
mNavigator->selectDates( d.addDays( val ), count );
block = false;
#endif
}
-
-void CalendarView::checkAlarms()
+void CalendarView::checkFiles()
{
-
QString message;
QPtrList<KopiCalendarFile> calendars = KOPrefs::instance()->mCalendars;
KopiCalendarFile * cal = calendars.first();
while ( cal ) {
if ( cal->mErrorOnLoad ) {
message += cal->mName +"\n"+KGlobal::formatMessage ( "(" +i18n( "Filepath: ")+ cal->mFileName+")" ,0 )+"\n";
}
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 ) );
int daysto = dt.daysTo( QDate::currentDate() );
int days = config->readNumEntry( "LatestProgramStopDays" , daysto);
dt = dt.addDays( days );
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h
index c9e9870..651194b 100644
--- a/korganizer/calendarview.h
+++ b/korganizer/calendarview.h
@@ -198,12 +198,13 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser
void updateSearchDialog();
void filtersUpdated();
public slots:
void checkAlarms();
+ void checkFiles();
void slotprintSelInc();
void showNextAlarms();
void showOpenError();
void watchSavedFile();
void recheckTimerAlarm();
void checkNextTimerAlarm();
diff --git a/korganizer/kofilterview.cpp b/korganizer/kofilterview.cpp
index 3cde103..20118aa 100644
--- a/korganizer/kofilterview.cpp
+++ b/korganizer/kofilterview.cpp
@@ -212,12 +212,13 @@ void KOCalEditView::infoCal( int id )
QString file = KGlobal::formatMessage ( KOPrefs::instance()->getCalendar( id )->mFileName, 0 );
if ( KOPrefs::instance()->getCalendar( id )->mErrorOnLoad ) {
if ( KMessageBox::Yes == KMessageBox::questionYesNo( this, i18n("The calendar <b>%1</b> is not loaded! Loading of file <b>%2</b> failed! <b>Try again to load the calendar?</b>").arg(name).arg(file) ) ) {
emit calendarAdded( id );
emit needsUpdate();
QTimer::singleShot( 0, this, SLOT ( readConfig() ) );
+ QTimer::singleShot( 100, this, SIGNAL ( checkCalendar() ) );
}
}
else
KMessageBox::information( this, i18n("The calendar <b>%1</b> is displaying file <b>%2</b>").arg(name).arg(file) );
}
void KOCalEditView::readConfig()
@@ -376,12 +377,13 @@ void KOCalEditView::addCal()
break;
}
kkf = KOPrefs::instance()->mCalendars.next();
}
}
addCalendar ( name, file );
+ QTimer::singleShot( 100, this, SIGNAL ( checkCalendar() ) );
}
int KOCalEditView::addCalendar( QString name, QString file, bool ask )
{
QFileInfo fi ( file );
if (!fi.exists() ) {
diff --git a/korganizer/kofilterview.h b/korganizer/kofilterview.h
index 54fe2c5..02107cf 100644
--- a/korganizer/kofilterview.h
+++ b/korganizer/kofilterview.h
@@ -230,12 +230,13 @@ class KOCalEditView : public QScrollView
void calendarEnabled ( int cal, bool enable );
void calendarReadonly ( int cal, bool readonly );
void setCalendarDefault ( int cal );
void removeCalendar ( int cal );
void calendarAdded( int );
void needsUpdate();
+ void checkCalendar();
private:
QWidget *mw;
void toggleList ( QPtrList<KOCalCheckButton> );
QPtrList<KOCalRadioButton> mStdandardB;
QPtrList<KOCalCheckButton> mEnabledB;
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index b797d8c..501eed5 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -395,17 +395,14 @@ MainWindow::MainWindow( QWidget *parent, const char *name ) :
updateFilterToolbar();
updateWeek( mView->startDate() );
connect( mView->dateNavigator(), SIGNAL( datesSelected( const KCal::DateList & ) ),
SLOT( updateWeekNum( const KCal::DateList & ) ) );
mBRdisabled = false;
//toggleBeamReceive();
- int tiint= 3000;
-#ifndef DESKTOP_VERSION
- tiint = 5000;
-#endif
- QTimer::singleShot( tiint, mView, SLOT ( checkAlarms() ));
+
+ QTimer::singleShot( 1000, mView, SLOT ( checkFiles() ));
}
MainWindow::~MainWindow()
{
//qDebug("MainWindow::~MainWindow() ");
//save toolbar location
delete mCalendar;