mirror of
https://github.com/gitui-org/gitui
synced 2026-05-23 17:08:21 +00:00
cargo fmt
This commit is contained in:
parent
33cced6312
commit
894314ccdc
3 changed files with 10 additions and 10 deletions
|
|
@ -65,9 +65,9 @@ impl Component for CreateBranchPopup {
|
|||
kind,
|
||||
state,
|
||||
}) => Cow::Owned(Event::Key(KeyEvent {
|
||||
code: KeyCode::Char(strings::normalize_branch_name_char(
|
||||
*c,
|
||||
)),
|
||||
code: KeyCode::Char(
|
||||
strings::normalize_branch_name_char(*c),
|
||||
),
|
||||
modifiers: *modifiers,
|
||||
kind: *kind,
|
||||
state: *state,
|
||||
|
|
|
|||
|
|
@ -65,9 +65,9 @@ impl Component for RenameBranchPopup {
|
|||
kind,
|
||||
state,
|
||||
}) => Cow::Owned(Event::Key(KeyEvent {
|
||||
code: KeyCode::Char(strings::normalize_branch_name_char(
|
||||
*c,
|
||||
)),
|
||||
code: KeyCode::Char(
|
||||
strings::normalize_branch_name_char(*c),
|
||||
),
|
||||
modifiers: *modifiers,
|
||||
kind: *kind,
|
||||
state: *state,
|
||||
|
|
|
|||
|
|
@ -439,10 +439,10 @@ pub fn ellipsis_trim_start(s: &str, width: usize) -> Cow<'_, str> {
|
|||
}
|
||||
|
||||
pub const fn normalize_branch_name_char(c: char) -> char {
|
||||
match c {
|
||||
' ' => '-',
|
||||
c => c,
|
||||
}
|
||||
match c {
|
||||
' ' => '-',
|
||||
c => c,
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(PartialEq, Eq, Clone, Copy)]
|
||||
|
|
|
|||
Loading…
Reference in a new issue