Skip to main content

run_host_switch_session

Function run_host_switch_session 

Source
pub async fn run_host_switch_session(
    keyboard: DeviceRoute,
    shutdown: Receiver<HostSwitchStopReason>,
    channel_pool: ChannelPool,
) -> Result<Option<u8>, HostSwitchError>
Expand description

Capture host switch keys on keyboard until one is pressed or shutdown resolves. Controls are restored before a requested host is returned.