aboutsummaryrefslogtreecommitdiffstats
path: root/default-plugins
diff options
context:
space:
mode:
authorAram Drevekenin <aram@poor.dev>2024-10-25 13:12:24 +0200
committerGitHub <noreply@github.com>2024-10-25 13:12:24 +0200
commit499fd64df83f1aa1563c3c7f99b4e19a6b833b4b (patch)
tree2f9e74cf3e92e5e26df74709b8acbcae296c9a14 /default-plugins
parentdocs(changelog): new themes (diff)
downloadsl0ppij-499fd64df83f1aa1563c3c7f99b4e19a6b833b4b.tar.gz
sl0ppij-499fd64df83f1aa1563c3c7f99b4e19a6b833b4b.tar.xz
sl0ppij-499fd64df83f1aa1563c3c7f99b4e19a6b833b4b.zip
style(fmt): remove warnings (#3701)
Diffstat (limited to 'default-plugins')
-rw-r--r--default-plugins/fixture-plugin-for-tests/src/main.rs4
-rw-r--r--default-plugins/session-manager/src/ui/components.rs2
-rw-r--r--default-plugins/tab-bar/src/line.rs8
3 files changed, 3 insertions, 11 deletions
diff --git a/default-plugins/fixture-plugin-for-tests/src/main.rs b/default-plugins/fixture-plugin-for-tests/src/main.rs
index 81ccc235..24f0f649 100644
--- a/default-plugins/fixture-plugin-for-tests/src/main.rs
+++ b/default-plugins/fixture-plugin-for-tests/src/main.rs
@@ -447,7 +447,7 @@ impl ZellijPlugin for State {
},
BareKey::Char('y') if key.has_modifiers(&[KeyModifier::Alt]) => {
let write_to_disk = true;
- let mut keys_to_unbind = vec![
+ let keys_to_unbind = vec![
(
InputMode::Locked,
KeyWithModifier::new(BareKey::Char('g')).with_ctrl_modifier(),
@@ -481,7 +481,7 @@ impl ZellijPlugin for State {
KeyWithModifier::new(BareKey::Char('g')).with_ctrl_modifier(),
),
];
- let mut keys_to_rebind = vec![
+ let keys_to_rebind = vec![
(
InputMode::Locked,
KeyWithModifier::new(BareKey::Char('a')).with_ctrl_modifier(),
diff --git a/default-plugins/session-manager/src/ui/components.rs b/default-plugins/session-manager/src/ui/components.rs
index 8bc09c24..29eba512 100644
--- a/default-plugins/session-manager/src/ui/components.rs
+++ b/default-plugins/session-manager/src/ui/components.rs
@@ -532,12 +532,10 @@ pub fn render_screen_toggle(
let key_indication_len = key_indication_text.chars().count() + 1;
let first_ribbon_length = new_session_text.chars().count() + 4;
let second_ribbon_length = running_sessions_text.chars().count() + 4;
- let third_ribbon_length = exited_sessions_text.chars().count() + 4;
let key_indication_x = x;
let first_ribbon_x = key_indication_x + key_indication_len;
let second_ribbon_x = first_ribbon_x + first_ribbon_length;
let third_ribbon_x = second_ribbon_x + second_ribbon_length;
- let reset_x = third_ribbon_x + third_ribbon_length + 1;
let mut new_session_text = Text::new(new_session_text);
let mut running_sessions_text = Text::new(running_sessions_text);
let mut exited_sessions_text = Text::new(exited_sessions_text);
diff --git a/default-plugins/tab-bar/src/line.rs b/default-plugins/tab-bar/src/line.rs
index 9384eaf1..d9f82698 100644
--- a/default-plugins/tab-bar/src/line.rs
+++ b/default-plugins/tab-bar/src/line.rs
@@ -1,14 +1,10 @@
use ansi_term::ANSIStrings;
-use ansi_term::{
- Color::{Fixed, RGB},
- Style,
-};
use unicode_width::UnicodeWidthStr;
use crate::{LinePart, ARROW_SEPARATOR};
use zellij_tile::prelude::actions::Action;
use zellij_tile::prelude::*;
-use zellij_tile_utils::{palette_match, style};
+use zellij_tile_utils::style;
fn get_current_title_len(current_title: &[LinePart]) -> usize {
current_title.iter().map(|p| p.len).sum()
@@ -251,7 +247,6 @@ pub fn tab_line(
} else {
tab_info.and_then(|tab_info| {
swap_layout_status(
- cols,
&tab_info.active_swap_layout_name,
tab_info.is_swap_layout_dirty,
mode_info,
@@ -307,7 +302,6 @@ pub fn tab_line(
}
fn swap_layout_status(
- cols: usize,
swap_layout_name: &Option<String>,
is_swap_layout_dirty: bool,
mode_info: &ModeInfo,