mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-03-28 15:40:54 +03:00
feat: simplify and change configuration (#279)
*breaking change* this changes the configuration syntax, allowing for an unlimited amount of configured clients. Also a first step towards enabling a "save config" feature.
This commit is contained in:
committed by
GitHub
parent
2f6a3629ad
commit
92f652df2e
@@ -4,13 +4,13 @@ use futures::StreamExt;
|
||||
use input_capture::{self, CaptureError, CaptureEvent, InputCapture, InputCaptureError, Position};
|
||||
use input_event::{Event, KeyboardEvent};
|
||||
|
||||
#[derive(Args, Debug, Eq, PartialEq)]
|
||||
#[derive(Args, Clone, Debug, Eq, PartialEq)]
|
||||
pub struct TestCaptureArgs {}
|
||||
|
||||
pub async fn run(config: Config, _args: TestCaptureArgs) -> Result<(), InputCaptureError> {
|
||||
log::info!("running input capture test");
|
||||
log::info!("creating input capture");
|
||||
let backend = config.capture_backend.map(|b| b.into());
|
||||
let backend = config.capture_backend().map(|b| b.into());
|
||||
loop {
|
||||
let mut input_capture = InputCapture::new(backend).await?;
|
||||
log::info!("creating clients");
|
||||
|
||||
Reference in New Issue
Block a user