From 39621c14dba229532247b6c4455e0870ba614ba6 Mon Sep 17 00:00:00 2001 From: alex-ds13 <145657253+alex-ds13@users.noreply.github.com> Date: Thu, 23 Jan 2025 10:38:16 +0000 Subject: [PATCH] fix(wm): stop wrongfully removing layout-flip This commit removes the code on the workspace `update` on `layout-rules` where it was setting the `layout-flip` to `None` if the layout was different from `BSP`. This appears to be some old code when the layout-flip would only apply to the `BSP` layout. However now it appears to apply to all layouts so this code shouldn't exist. This commit also changes the docs from the `FlipLayout` command to remove the statement that only applied to `BSP` since it is no longer true. --- komorebi/src/workspace.rs | 4 ---- komorebic/src/main.rs | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/komorebi/src/workspace.rs b/komorebi/src/workspace.rs index 6b09e84e..7d3fa96c 100644 --- a/komorebi/src/workspace.rs +++ b/komorebi/src/workspace.rs @@ -333,10 +333,6 @@ impl Workspace { } if let Some(updated_layout) = updated_layout { - if !matches!(updated_layout, Layout::Default(DefaultLayout::BSP)) { - self.set_layout_flip(None); - } - self.set_layout(updated_layout); } } diff --git a/komorebic/src/main.rs b/komorebic/src/main.rs index ca8b647f..161a9037 100644 --- a/komorebic/src/main.rs +++ b/komorebic/src/main.rs @@ -1175,7 +1175,7 @@ enum SubCommand { #[clap(hide = true)] #[clap(arg_required_else_help = true)] LoadCustomLayout(LoadCustomLayout), - /// Flip the layout on the focused workspace (BSP only) + /// Flip the layout on the focused workspace #[clap(arg_required_else_help = true)] FlipLayout(FlipLayout), /// Promote the focused window to the top of the tree