summaryrefslogtreecommitdiffabout
path: root/libkcal
Side-by-side diff
Diffstat (limited to 'libkcal') (more/less context) (show whitespace changes)
-rw-r--r--libkcal/todo.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/libkcal/todo.cpp b/libkcal/todo.cpp
index 473247a..38ba2c7 100644
--- a/libkcal/todo.cpp
+++ b/libkcal/todo.cpp
@@ -560,18 +560,21 @@ QDateTime Todo::getNextAlarmDateTime( bool * ok, int * offset, QDateTime start_d
*ok = false;
return QDateTime ();
}
void Todo::checkSetCompletedFalse()
{
if ( !hasRecurrenceID() ) {
qDebug("ERROR 1 in Todo::checkSetCompletedFalse");
}
// qDebug("Todo::checkSetCompletedFalse()");
//qDebug("%s %s %s ",mDtStart.toString().latin1(), dtDue().toString().latin1(),mRecurrenceID.toString().latin1() );
- if ( mPercentComplete == 100 && mDtStart == mRecurrenceID && QDateTime::currentDateTime() > mDtStart) {
- qDebug("%s %s %s ",mDtStart.toString().latin1(), dtDue().toString().latin1(),mRecurrenceID.toString().latin1() );
+ if ( mPercentComplete == 100 ) {
+ QDateTime dt = QDateTime::currentDateTime();
+ if ( dt > mDtStart && dt > mRecurrenceID ) {
+ qDebug("start: %s --due: %s --recID: %s ",mDtStart.toString().latin1(), dtDue().toString().latin1(),mRecurrenceID.toString().latin1() );
setCompleted( false );
qDebug("Todo::checkSetCompletedFalse ");
}
}
+}