diff options
| author | Aram Drevekenin <aram@poor.dev> | 2026-02-24 13:10:40 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-02-24 13:10:40 +0100 |
| commit | 8cd6286c3ffc10d14fdafd5005fa89b0f7fdcd44 (patch) | |
| tree | c6341f5e3e251ae17db0c3427ddaf1e54d4fa91c /default-plugins/sequence/src/state/command_entry.rs | |
| parent | Allow closing replaced panes when opening panes in place (#4760) (diff) | |
| download | sl0ppij-8cd6286c3ffc10d14fdafd5005fa89b0f7fdcd44.tar.gz sl0ppij-8cd6286c3ffc10d14fdafd5005fa89b0f7fdcd44.tar.xz sl0ppij-8cd6286c3ffc10d14fdafd5005fa89b0f7fdcd44.zip | |
remove sequence plugin (#4761)
Diffstat (limited to 'default-plugins/sequence/src/state/command_entry.rs')
| -rw-r--r-- | default-plugins/sequence/src/state/command_entry.rs | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/default-plugins/sequence/src/state/command_entry.rs b/default-plugins/sequence/src/state/command_entry.rs deleted file mode 100644 index 4ca9350a..00000000 --- a/default-plugins/sequence/src/state/command_entry.rs +++ /dev/null @@ -1,76 +0,0 @@ -use super::{ChainType, CommandStatus}; -use std::path::PathBuf; -use zellij_tile::prelude::PaneId; - -#[derive(Debug, Clone)] -pub struct CommandEntry { - text: String, - cwd: Option<PathBuf>, - pub(super) chain_type: ChainType, - pub(super) status: CommandStatus, -} - -impl Default for CommandEntry { - fn default() -> Self { - CommandEntry { - text: String::default(), - cwd: None, - chain_type: ChainType::default(), - status: CommandStatus::default(), - } - } -} - -impl CommandEntry { - pub fn new(text: &str, cwd: Option<PathBuf>) -> Self { - CommandEntry { - text: text.to_owned(), - cwd, - ..Default::default() - } - } - pub fn get_text(&self) -> String { - self.text.clone() - } - pub fn set_text(&mut self, text: String) { - self.text = text; - } - pub fn clear_text(&mut self) { - self.text.clear(); - } - pub fn get_chain_type(&self) -> ChainType { - self.chain_type - } - pub fn set_chain_type(&mut self, chain_type: ChainType) { - self.chain_type = chain_type; - } - pub fn get_status(&self) -> CommandStatus { - self.status.clone() - } - pub fn set_status(&mut self, status: CommandStatus) { - self.status = status; - } - pub fn get_pane_id(&self) -> Option<PaneId> { - self.status.get_pane_id() - } - pub fn is_empty(&self) -> bool { - self.text.trim().is_empty() - } - pub fn fill_chain_type_if_empty(&mut self) { - if let ChainType::None = self.chain_type { - self.chain_type = ChainType::And; - } - } - pub fn clear_chain_type(&mut self) { - self.chain_type = ChainType::None; - } - pub fn clear_status(&mut self) { - self.status = CommandStatus::Pending; - } - pub fn get_cwd(&self) -> Option<PathBuf> { - self.cwd.clone() - } - pub fn set_cwd(&mut self, cwd: Option<PathBuf>) { - self.cwd = cwd; - } -} |
