Skip to main content

Module signal

Module signal 

Source
Expand description

Implements placing a signal to a specific segment.

Structs§

PositionIndicator
Simple indicator of the current location where the signal will be placed.
SignalEditorPlugin
Implements placing a signal to a specific segment.
TargetSegment
Tracks to which track we want to place the signal.

Functions§

input_handler
Handles switching inputs for changing the side of the track where the signal is going to be placed and canceling the operation.
on_enter_signal
Handles going into EditorState::Signal, spawning the position indicator and changing the state text.
on_exit_signal
Handles going out of EditorState::Signal, removing the position indicator and going back to the segment’s window.
place_signal
Places the signal on left click.
update_pos_indicator
Updates TrackPos of PositionIndicator to the current projection of the cursor position to the target segment.