Refactor meridian state capture logic to state machine
Next step towards dedicated state machines: Shift meridian state handling from Capture to the module's state machine. With this change, the entire state handling of a meridian flip is now encapsulated inside CaptureModuleState
.
In detail, this contains the following changes:
-
CaptureModuleState::updateMFMountState
, which is the central entry point for all meridian flip status changes ofMount
has been moved here fromCapture::meridianFlipStatusChanged
. With this change now the entire functional translation of the mount module perspective upon meridian flips into the broader meridian flip state of theCapture
module now is part of the state machine. - The signals
newMeridianFlipStage
andmeridianFlipStarted
are now sent from the state machine. -
Capture::setMeridianFlipStage
has been renamed toCapture::updateMeridianFlipStage
and contains now only UI updates, all functional parts have been relocated toCaptureModuleState::updateMeridianFlipStage
. -
Capture::updateMFMountState
is the new and forwards the mount meridian flip states to the capture state machine. This indirection is necessary since the state forwarding happens inside of theManager
and the capture state machine is not publicly visible. -
Capture::isGuidingOn
is moved toCaptureModuleState
. - The pause function - i.e. the function to continue after pausing - now is a static attribute in
CaptureModuleState
instead of a function link insideCapture
.
After this change, only parts of the post meridian flip handling remains inside Capture
, which will be subject to a subsequent refactoring.
Edited by Wolfgang Reissenberger