diff --git a/client/src/config/binds.rs b/client/src/config/binds.rs index d122121..8c4bed9 100644 --- a/client/src/config/binds.rs +++ b/client/src/config/binds.rs @@ -1,5 +1,7 @@ // src/config/binds.rs pub mod config; +pub mod key_sequences; pub use config::*; +pub use key_sequences::*; diff --git a/client/src/config/binds/config.rs b/client/src/config/binds/config.rs index ea0d4ec..c3c2f41 100644 --- a/client/src/config/binds/config.rs +++ b/client/src/config/binds/config.rs @@ -355,13 +355,13 @@ impl Config { // Get string representations of the sequence let sequence_str = sequence.iter() - .map(|k| crate::config::key_sequences::key_to_string(k)) + .map(|k| crate::config::binds::key_sequences::key_to_string(k)) .collect::>() .join(""); // Add the missing sequence_plus definition let sequence_plus = sequence.iter() - .map(|k| crate::config::key_sequences::key_to_string(k)) + .map(|k| crate::config::binds::key_sequences::key_to_string(k)) .collect::>() .join("+"); @@ -414,7 +414,7 @@ impl Config { // Special case for + format in bindings if binding.contains('+') { let normalized_sequence = sequence.iter() - .map(|k| crate::config::key_sequences::key_to_string(k)) + .map(|k| crate::config::binds::key_sequences::key_to_string(k)) .collect::>(); let binding_parts: Vec<&str> = binding.split('+').collect(); @@ -442,7 +442,7 @@ impl Config { // Get string representation of the sequence let sequence_str = sequence.iter() - .map(|k| crate::config::key_sequences::key_to_string(k)) + .map(|k| crate::config::binds::key_sequences::key_to_string(k)) .collect::>() .join(""); @@ -491,7 +491,7 @@ impl Config { if binding.contains('+') { let binding_parts: Vec<&str> = binding.split('+').collect(); let sequence_parts = sequence.iter() - .map(|k| crate::config::key_sequences::key_to_string(k)) + .map(|k| crate::config::binds::key_sequences::key_to_string(k)) .collect::>(); if binding_parts.len() > sequence_parts.len() { diff --git a/client/src/config/key_sequences.rs b/client/src/config/binds/key_sequences.rs similarity index 100% rename from client/src/config/key_sequences.rs rename to client/src/config/binds/key_sequences.rs diff --git a/client/src/config/mod.rs b/client/src/config/mod.rs index d40f179..7668248 100644 --- a/client/src/config/mod.rs +++ b/client/src/config/mod.rs @@ -1,5 +1,4 @@ // src/config/mod.rs -pub mod key_sequences; pub mod binds; pub mod colors; diff --git a/client/src/modes/handlers/event.rs b/client/src/modes/handlers/event.rs index 602594e..497a304 100644 --- a/client/src/modes/handlers/event.rs +++ b/client/src/modes/handlers/event.rs @@ -10,7 +10,7 @@ use crate::config::binds::config::Config; use crate::ui::handlers::form::FormState; use crate::ui::handlers::rat_state::UiStateHandler; use crate::modes::handlers::{edit, command_mode, read_only}; -use crate::config::key_sequences::KeySequenceTracker; +use crate::config::binds::key_sequences::KeySequenceTracker; use super::common; pub struct EventHandler { diff --git a/client/src/modes/handlers/read_only.rs b/client/src/modes/handlers/read_only.rs index 19f5de6..7743084 100644 --- a/client/src/modes/handlers/read_only.rs +++ b/client/src/modes/handlers/read_only.rs @@ -3,7 +3,7 @@ use crossterm::event::{KeyEvent}; use crate::config::binds::config::Config; use crate::ui::handlers::form::FormState; -use crate::config::key_sequences::KeySequenceTracker; +use crate::config::binds::key_sequences::KeySequenceTracker; use crate::tui::terminal::grpc_client::GrpcClient; #[derive(PartialEq)]