GO supports two types of divisionals: manual divisionals ("old style") and setter divisionals ("banked").
Processing divisional couplers was made in GOSetter::PushDivisional(). Unfortunally it supported only the first type (manual) divisionals and knew nothing about the setter divisionals. So when a setter divisional was poshed, GOSetter::PushDivisional tried to couple it with a manual divisional with the same number without checking whether it exist. It caused a crash.
This PR
Extracts collecting coupled manuals from GOSetter::PushDivisional() to GOOrganModel::FillCoupledManualsForDivisional and GODivisionalCoupler::GetCoupledManuals
Extract the current processing of divisional coupler with manual divisionals from GOSetter::PushDivisional() to GODivisionalButtonControl::Push()
GOSetter::PushDivisional() becomes very simple without any coupler processing. It fixes the crash mentioned in #1787
Because GODivisionalSetter::SwitchDivisionalTo calls GOSetter::PushDivisional() that stops processing couplers, the divisional couplers still do not work with the setter divisionals, but they do not more cause crash.
Fix of working divisional couplers with the setter divisionals will be submitted after merging this PR.
This is the first PR related to #1787.
GO supports two types of divisionals: manual divisionals ("old style") and setter divisionals ("banked").
Processing divisional couplers was made in GOSetter::PushDivisional(). Unfortunally it supported only the first type (manual) divisionals and knew nothing about the setter divisionals. So when a setter divisional was poshed, GOSetter::PushDivisional tried to couple it with a manual divisional with the same number without checking whether it exist. It caused a crash.
This PR
GOSetter::PushDivisional()
toGOOrganModel::FillCoupledManualsForDivisional
andGODivisionalCoupler::GetCoupledManuals
GOSetter::PushDivisional()
toGODivisionalButtonControl::Push()
GOSetter::PushDivisional()
becomes very simple without any coupler processing. It fixes the crash mentioned in #1787Because
GODivisionalSetter::SwitchDivisionalTo
callsGOSetter::PushDivisional()
that stops processing couplers, the divisional couplers still do not work with the setter divisionals, but they do not more cause crash.Fix of working divisional couplers with the setter divisionals will be submitted after merging this PR.