generated from GarandPLG/rust-flake-template
Refactor to View enum and add keybindings
Replace the `default_window` string field with a `View` enum throughout the application. Introduce a new keybinding module providing `Action`, `KeyBinding` structs and helper functions, and integrate a keybindings widget into the main menu. Update the CLI to accept a `View` value enum and adjust imports and event handling accordingly. Add a release profile in `Cargo.toml` with LTO, single codegen unit, higher optimisation level and binary stripping for smaller, faster builds.
This commit is contained in:
1 parent
64eb906b5f
commit
de42569a51
10 files changed
+147
-43
No files matched your search
+5
-1
@@ -1,5 +1,9 @@
|
||||
pub mod app;
|
||||
pub mod keybindings;
|
||||
pub mod widget;
|
||||
pub mod widgets;
|
||||
|
||||
pub use app::{App, Event, handle_input_events};
|
||||
pub use app::{App, Event, View, handle_input_events};
|
||||
pub use keybindings::{
|
||||
Action, KEYBINDINGS, KeyBinding, binding_for, binding_for_view, event_to_action,
|
||||
};
|
||||
Reference in new issue
Block a user