Page MenuHomekolab.org

Fix timeSpan for a series with exceptions
ClosedPublic

Authored by knauss on May 25 2016, 7:37 PM.

Details

Summary

When having a time series with exceptions, that have the ThisAndFurute argument,
we need also to take this into account if we calucate the iterator for occurences
for a timespan, that begins after the exception has started.

Diff Detail

Repository
rKPL kdepimlibs
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

knauss updated this revision to Diff 358.May 25 2016, 7:37 PM
knauss retitled this revision from to Fix timeSpan for a series with exceptions.
knauss updated this object.
knauss added a reviewer: mollekopf.
mollekopf requested changes to this revision.Jun 8 2016, 2:01 PM
mollekopf edited edge metadata.
mollekopf added inline comments.
kcalcore/occurrenceiterator.cpp
112

lastInc and lastOffset seem to be unused?
Either remove, or otherwise you probably also have to adjust lastInc when setting the exception on incidence.

This revision now requires changes to proceed.Jun 8 2016, 2:01 PM
knauss added inline comments.Jun 9 2016, 11:42 AM
kcalcore/occurrenceiterator.cpp
112

No lastInc and lastOffset are used later on in the next for loop ( l151, l162).

So we can move the two variables back to ther further position. But on the other side lastOffset and lastInc are used internally in the for loop and only need to valid if resetIncidence is True.

IMO I think just leave it like i did now, because otherwise we would mix cleanup & patching.

mollekopf accepted this revision.Jun 9 2016, 11:52 AM
mollekopf edited edge metadata.

Makes sense

This revision is now accepted and ready to land.Jun 9 2016, 11:52 AM
Closed by commit rKPL4601bd74e3d3: Fix timeSpan for a series with exceptions (authored by Sandro Knauß <sknauss@kde.org>). · Explain WhyJun 9 2016, 12:10 PM
This revision was automatically updated to reflect the committed changes.