diff --git a/src/backend/common.rs b/src/backend/common.rs index 16d963d..842f1c7 100644 --- a/src/backend/common.rs +++ b/src/backend/common.rs @@ -150,7 +150,7 @@ where self.overlays.values_mut().for_each(|o| { if o.state.show_hide { o.state.want_visible = !any_shown; - if o.state.want_visible && o.state.recenter { + if o.state.want_visible && app.session.config.realign_on_showhide && o.state.recenter { o.state.reset(app, false); } } diff --git a/src/config.rs b/src/config.rs index dbc101b..6d9e890 100644 --- a/src/config.rs +++ b/src/config.rs @@ -148,6 +148,9 @@ pub struct GeneralConfig { #[serde(default = "def_true")] pub allow_sliding: bool, + + #[serde(default = "def_true")] + pub realign_on_showhide: bool, } impl GeneralConfig { diff --git a/src/res/config.yaml b/src/res/config.yaml index 33fa4eb..52bf9bb 100644 --- a/src/res/config.yaml +++ b/src/res/config.yaml @@ -15,3 +15,7 @@ watch_scale: 1.0 # Enable / disable sliding windows back and forth with the scroll action # Default: true allow_sliding: true + +# Enable / disable realigning the working set windows when they are shown/hidden +# Default: true +realign_on_showhide: true