From c3dd5bfd446b893a8b39ddec425a6cf8deff2261 Mon Sep 17 00:00:00 2001 From: zautrix Date: Wed, 09 Feb 2005 13:22:06 +0000 Subject: fixes --- (limited to 'korganizer/kowhatsnextview.cpp') diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp index 10665f4..391b3bb 100644 --- a/korganizer/kowhatsnextview.cpp +++ b/korganizer/kowhatsnextview.cpp @@ -615,7 +615,11 @@ bool KOWhatsNextView::appendEvent(Incidence *ev, bool reply, bool notRed, bool a if ( bDay ) { noc = ev->getNextOccurence( cdt.addDays(-1), &ok ); if ( ok ) { - int years = noc.date().year() - ev->dtStart().date().year(); + int years = 0; + if ( ev->type() =="Todo" ) { + years = noc.date().year() -((Todo*)ev)->dtDue().date().year(); + } else + years = noc.date().year() - ev->dtStart().date().year(); tempText += i18n(" (%1 y.)"). arg( years ); } } -- cgit v0.9.0.2