Simplify KeyGroup
The trait will only be used for documenting the key bindings in the F1 menu from now on. The InputEvent will be directly match-eable against KeyBinding-s, which should suffice for input event handling.
This commit is contained in:
parent
6ce2afbc9f
commit
64a7e7f518
2 changed files with 13 additions and 33 deletions
|
|
@ -8,7 +8,5 @@ pub use keys::*;
|
|||
|
||||
/// A group of related key bindings.
|
||||
pub trait KeyGroup {
|
||||
type Event;
|
||||
|
||||
fn match_input_event(&self, event: &mut InputEvent) -> Option<Self::Event>;
|
||||
fn bindings(&self) -> Vec<(&KeyBinding, &'static str)>;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue