mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-09-30 17:36:40 +00:00
set a new start time of the race in the timeslider if we get a good calculation from the leg times retreival
This commit is contained in:
1 parent
7176393039
commit
c7e9900bc3
1 file changed
+7
-1
+7
-1
@@ -239,8 +239,14 @@ public class RaceBoardPanel extends FormPanel implements EventDisplayer, RaceSel
|
||||
@Override
|
||||
public void onSuccess(RaceTimesInfoDTO racesTimesInfo) {
|
||||
timePanel.setLegMarkers(racesTimesInfo.getLegTimes());
|
||||
if (racesTimesInfo.getStartOfRace() != null)
|
||||
if (racesTimesInfo.getStartOfRace() != null) {
|
||||
// set the new start time
|
||||
Date startOfRace = racesTimesInfo.getStartOfRace();
|
||||
Date startOfTimeslider = new Date(startOfRace.getTime() - 5 * 60 * 1000);
|
||||
|
||||
timePanel.changeMin(startOfTimeslider);
|
||||
timer.setTime(racesTimesInfo.getStartOfRace().getTime());
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user