use keyflow::prelude::*;
use std::thread;
use std::time::Duration;
fn main() -> Result<()> {
Keyflow::builder()
.with_screen(Screen::new(-1920, 0, 3840, 1080))
.initialize()?;
thread::sleep(Duration::from_secs(2));
Keyflow::move_to(960, 540);
thread::sleep(Duration::from_millis(1000));
Keyflow::move_to(0, 0);
thread::sleep(Duration::from_millis(1000));
Keyflow::move_to(1920, 0);
thread::sleep(Duration::from_millis(1000));
Keyflow::move_to(1920, 1080);
thread::sleep(Duration::from_millis(1000));
Keyflow::move_to(-1920, 0);
thread::sleep(Duration::from_millis(1000));
for x in (-1920..=1920).step_by(50) {
Keyflow::move_to(x, 540);
thread::sleep(Duration::from_millis(10));
}
Keyflow::move_by(-1920, 0);
Ok(())
}