mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-17 01:31:01 +00:00
update the cachedRacingProcedureTypeNoFallback field in ReadonlyRaceStateImpl which was formerly missing, missing a change to GateStart
Change-Id: I28364884f374a8960d4a5a7341da195e74dad88b
This commit is contained in:
1 parent
89e62a579d
commit
158be53da0
1 file changed
+7
-1
+7
-1
@@ -231,8 +231,12 @@ public class ReadonlyRaceStateImpl implements ReadonlyRaceState, RaceLogChangedL
|
||||
protected RacingProcedureType determineInitialProcedureType() {
|
||||
// Let's ensure there is a valid RacingProcedureType set, since a RaceState cannot live without a
|
||||
// RacingProcedure we need to have a fallback
|
||||
RegattaConfiguration configuration = getConfiguration();
|
||||
RacingProcedureType inRaceLogType = racingProcedureAnalyzer.analyze();
|
||||
return determineInitialProcedureType(inRaceLogType);
|
||||
}
|
||||
|
||||
private RacingProcedureType determineInitialProcedureType(RacingProcedureType inRaceLogType) {
|
||||
RegattaConfiguration configuration = getConfiguration();
|
||||
if (inRaceLogType != RacingProcedureType.UNKNOWN) {
|
||||
return inRaceLogType;
|
||||
} else {
|
||||
@@ -416,6 +420,7 @@ public class ReadonlyRaceStateImpl implements ReadonlyRaceState, RaceLogChangedL
|
||||
RacingProcedureType type = racingProcedureAnalyzer.analyze();
|
||||
if (!Util.equalsWithNull(cachedRacingProcedureType, type) && type != RacingProcedureType.UNKNOWN) {
|
||||
cachedRacingProcedureType = type;
|
||||
cachedRacingProcedureTypeNoFallback = determineInitialProcedureType(type);
|
||||
recreateRacingProcedure();
|
||||
changedListeners.onRacingProcedureChanged(this);
|
||||
}
|
||||
@@ -432,6 +437,7 @@ public class ReadonlyRaceStateImpl implements ReadonlyRaceState, RaceLogChangedL
|
||||
changedListeners.onAdvancePass(this);
|
||||
// reset racing procedure to force recreate on next event!
|
||||
cachedRacingProcedureType = null;
|
||||
cachedRacingProcedureTypeNoFallback = null;
|
||||
}
|
||||
|
||||
StartTimeFinderResult startTimeFinderResult = startTimeAnalyzer.analyze();
|
||||
|
||||
Reference in new issue
Block a user