use crate::*;
/// A mapping from pedal actions to requests.
///
/// Each pedal is either pressed or not.
/// When a pedal is pressed, [`PedalMapper::on_press`] is called with the just-pressed pedal.
/// When the pedal is released, [`PedalMapper::on_release`] is called with the just-released pedal.
///
/// Pedals are variants of either [`ThreePedals`] or [`SixPedals`] depending on
/// whether the system has one or two planes.
/// Resolve requests into X-ray controller actions.
///
/// For example you might get a request to start a low dose video with the frontal projection,
/// but because there are other pedals pressed you might choose to ignore it or do something else.
/// This is where that decision logic goes.
///
/// The [`ActionLogic::handle_request`] function also gets a mutable reference to `self` so it is possible
/// to modify and check the state of your system. You could, for example, keep track of the
/// currently selected projection, and then modify it when you get a [`Request::ToggleSelectedProjection`].
///
/// Requests are synchronous and handled in the same order that they are sent.