diff options
author | Ken Matsui <26405363+ken-matsui@users.noreply.github.com> | 2022-02-24 19:07:09 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-24 11:07:09 +0100 |
commit | e73ce08ddf57b8d4a7f10203e197fc5c967cf892 (patch) | |
tree | 79b4cde97db0d6b10f78fe3c9d54ef8e5c7c0dad /zellij-server/src/ui | |
parent | 645735f5717170c9edefecae2b58aaa4fec123f7 (diff) |
fix(style): remove redundant `.clone()` calls (#1085)
Diffstat (limited to 'zellij-server/src/ui')
-rw-r--r-- | zellij-server/src/ui/pane_boundaries_frame.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/zellij-server/src/ui/pane_boundaries_frame.rs b/zellij-server/src/ui/pane_boundaries_frame.rs index c46e55342..c4dfc0fd2 100644 --- a/zellij-server/src/ui/pane_boundaries_frame.rs +++ b/zellij-server/src/ui/pane_boundaries_frame.rs @@ -142,23 +142,23 @@ impl PaneFrame { } } fn render_my_focus(&self, max_length: usize) -> Option<(Vec<TerminalCharacter>, usize)> { - let left_separator = foreground_color(boundary_type::VERTICAL_LEFT, self.color); - let right_separator = foreground_color(boundary_type::VERTICAL_RIGHT, self.color); + let mut left_separator = foreground_color(boundary_type::VERTICAL_LEFT, self.color); + let mut right_separator = foreground_color(boundary_type::VERTICAL_RIGHT, self.color); let full_indication_text = "MY FOCUS"; let mut full_indication = vec![]; - full_indication.append(&mut left_separator.clone()); + full_indication.append(&mut left_separator); full_indication.push(EMPTY_TERMINAL_CHARACTER); full_indication.append(&mut foreground_color(full_indication_text, self.color)); full_indication.push(EMPTY_TERMINAL_CHARACTER); - full_indication.append(&mut right_separator.clone()); + full_indication.append(&mut right_separator); let full_indication_len = full_indication_text.width() + 4; // 2 for separators 2 for padding let short_indication_text = "ME"; let mut short_indication = vec![]; - short_indication.append(&mut left_separator.clone()); + short_indication.append(&mut left_separator); short_indication.push(EMPTY_TERMINAL_CHARACTER); short_indication.append(&mut foreground_color(short_indication_text, self.color)); short_indication.push(EMPTY_TERMINAL_CHARACTER); - short_indication.append(&mut right_separator.clone()); + short_indication.append(&mut right_separator); let short_indication_len = short_indication_text.width() + 4; // 2 for separators 2 for padding if full_indication_len <= max_length { Some((full_indication, full_indication_len)) |