-rw-r--r-- | library/datebookdb.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/library/datebookdb.cpp b/library/datebookdb.cpp index 0fedfa8..2f33255 100644 --- a/library/datebookdb.cpp +++ b/library/datebookdb.cpp | |||
@@ -70,9 +70,9 @@ bool nextOccurance(const Event &e, const QDate &from, QDateTime &next) | |||
70 | int iday, imonth, iyear; | 70 | int iday, imonth, iyear; |
71 | int dayOfWeek = 0; | 71 | int dayOfWeek = 0; |
72 | int firstOfWeek = 0; | 72 | int firstOfWeek = 0; |
73 | int weekOfMonth; | 73 | int weekOfMonth; |
74 | 74 | ||
75 | 75 | ||
76 | if (e.repeatPattern().hasEndDate && e.repeatPattern().endDate() < from) | 76 | if (e.repeatPattern().hasEndDate && e.repeatPattern().endDate() < from) |
77 | return FALSE; | 77 | return FALSE; |
78 | 78 | ||
@@ -460,9 +460,9 @@ QValueList<EffectiveEvent> DateBookDB::getEffectiveEvents( const QDate &from, | |||
460 | QDateTime dtTmp, | 460 | QDateTime dtTmp, |
461 | dtEnd; | 461 | dtEnd; |
462 | 462 | ||
463 | for (it = eventList.begin(); it != eventList.end(); ++it ) { | 463 | for (it = eventList.begin(); it != eventList.end(); ++it ) { |
464 | if (!(*it).isValidUid()) | 464 | if (!(*it).isValidUid()) |
465 | (*it).assignUid(); // FIXME: Hack to restore cleared uids | 465 | (*it).assignUid(); // FIXME: Hack to restore cleared uids |
466 | 466 | ||
467 | dtTmp = (*it).start(TRUE); | 467 | dtTmp = (*it).start(TRUE); |
468 | dtEnd = (*it).end(TRUE); | 468 | dtEnd = (*it).end(TRUE); |
@@ -505,9 +505,9 @@ QValueList<EffectiveEvent> DateBookDB::getEffectiveEvents( const QDate &from, | |||
505 | } | 505 | } |
506 | // check for repeating events... | 506 | // check for repeating events... |
507 | QDateTime repeat; | 507 | QDateTime repeat; |
508 | for ( it = repeatEvents.begin(); it != repeatEvents.end(); ++it ) { | 508 | for ( it = repeatEvents.begin(); it != repeatEvents.end(); ++it ) { |
509 | if (!(*it).isValidUid()) | 509 | if (!(*it).isValidUid()) |
510 | (*it).assignUid(); // FIXME: Hack to restore cleared uids | 510 | (*it).assignUid(); // FIXME: Hack to restore cleared uids |
511 | 511 | ||
512 | /* create a false end date, to short circuit on hard | 512 | /* create a false end date, to short circuit on hard |
513 | MonthlyDay recurences */ | 513 | MonthlyDay recurences */ |
@@ -622,9 +622,9 @@ void DateBookDB::editEvent( const Event &old, Event &editedEv ) | |||
622 | // Delete old event | 622 | // Delete old event |
623 | if ( old.hasAlarm() ) | 623 | if ( old.hasAlarm() ) |
624 | delEventAlarm( old ); | 624 | delEventAlarm( old ); |
625 | if ( oldHadRepeat ) { | 625 | if ( oldHadRepeat ) { |
626 | if ( editedEv.hasRepeat() ) { // This mean that origRepeat was run above and | 626 | if ( editedEv.hasRepeat() ) { // This mean that origRepeat was run above and |
627 | // orig is initialized | 627 | // orig is initialized |
628 | // assumption, when someone edits a repeating event, they | 628 | // assumption, when someone edits a repeating event, they |
629 | // want to change them all, maybe not perfect, but it works | 629 | // want to change them all, maybe not perfect, but it works |
630 | // for the moment... | 630 | // for the moment... |
@@ -671,9 +671,9 @@ void DateBookDB::removeJFEvent( const Event&ev ) | |||
671 | 671 | ||
672 | // also handles journaling... | 672 | // also handles journaling... |
673 | void DateBookDB::loadFile( const QString &strFile ) | 673 | void DateBookDB::loadFile( const QString &strFile ) |
674 | { | 674 | { |
675 | 675 | ||
676 | QFile f( strFile ); | 676 | QFile f( strFile ); |
677 | if ( !f.open( IO_ReadOnly ) ) | 677 | if ( !f.open( IO_ReadOnly ) ) |
678 | return; | 678 | return; |
679 | 679 | ||
@@ -722,9 +722,9 @@ void DateBookDB::loadFile( const QString &strFile ) | |||
722 | dict.insert( "action", new int(FAction) ); | 722 | dict.insert( "action", new int(FAction) ); |
723 | dict.insert( "actionkey", new int(FActionKey) ); | 723 | dict.insert( "actionkey", new int(FActionKey) ); |
724 | dict.insert( "actionorig", new int (FJournalOrigHadRepeat) ); | 724 | dict.insert( "actionorig", new int (FJournalOrigHadRepeat) ); |
725 | 725 | ||
726 | 726 | ||
727 | QByteArray ba = f.readAll(); | 727 | QByteArray ba = f.readAll(); |
728 | char* dt = ba.data(); | 728 | char* dt = ba.data(); |
729 | int len = ba.size(); | 729 | int len = ba.size(); |
730 | int currentAction, | 730 | int currentAction, |