Skip to content

Commit

Permalink
Fixed LTM Chart to show Events on Phases and Season end date
Browse files Browse the repository at this point in the history
Events ocurring on Season end date were not showing
Seasons ending, but not starting, on chart date range were not considered when looking for events
Fixes GoldenCheetah#2620
  • Loading branch information
amtriathlon committed Mar 18, 2018
1 parent ecd5b15 commit 07b18e6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/Charts/LTMPlot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4028,10 +4028,9 @@ LTMPlot::refreshMarkers(LTMSettings *settings, QDate from, QDate to, int groupby

foreach (Season s, tmpSeasons) {
/* if (s.type != Season::temporary && s.name != settings->title && s.getStart() >= from && s.getStart() < to) { */
if (s.getStart() >= from && s.getStart() < to) {
if ((s.getStart() >= from && s.getStart() <= to) || (s.getEnd() >= from && s.getEnd() <= to)) {
foreach (SeasonEvent event, s.events) {

if (event.date > from && event.date < to) {
if (event.date >= from && event.date <= to) {

// and the events...
QwtIndPlotMarker *mrk = new QwtIndPlotMarker;
Expand Down

0 comments on commit 07b18e6

Please sign in to comment.