fumble 0.6.1

an oxidized implementation of the original clumsy tool, designed to simulate adverse network conditions on Windows systems.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use ratatui::crossterm::event::KeyEvent;

pub trait HandleInput {
    fn handle_input(&mut self, key: KeyEvent) -> bool;
}

pub trait DisplayName {
    fn name(&self) -> &str;
}

pub trait KeyBindings {
    fn key_bindings(&self) -> String; // or Vec<String> if there are multiple bindings
}

pub trait IsActive {
    fn is_active(&self) -> bool;
    fn set_active(&mut self, state: bool);
}