Skip to content

Commit 216f391

Browse files
authored
fix: atomic floating pane issues with the about screen (#4834)
* fix: atomic floating pane issues with the about screen * rustfmt * add pr
1 parent 578a7db commit 216f391

File tree

3 files changed

+17
-12
lines changed

3 files changed

+17
-12
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
7777
* feat: `zellij action paste` for pasting large buffers into panes from the command line (https://github.com/zellij-org/zellij/pull/4817)
7878
* feat: allow dumping viewport of specific pane to STDOUT or to a file (https://github.com/zellij-org/zellij/pull/4598 and https://github.com/zellij-org/zellij/pull/4823)
7979
* fix: allow specifying --ip and --port with `zellij web --status` rather than relying on those in the config (https://github.com/zellij-org/zellij/pull/4825)
80+
* fix: make sure clients are focused when atomically showing floating panes (https://github.com/zellij-org/zellij/pull/4834)
8081

8182

8283
## [0.43.1] - 2025-08-08

default-plugins/about/src/main.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,7 @@ impl App {
311311
)
312312
.unwrap(),
313313
)]);
314+
let _ = show_floating_panes(None);
314315
}
315316
}
316317
}

zellij-server/src/tab/mod.rs

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4914,19 +4914,22 @@ impl Tab {
49144914
if let Some(c) = completion.as_mut() {
49154915
c.set_exit_status(2);
49164916
}
4917-
} else if self
4918-
.floating_panes
4919-
.last_selectable_floating_pane_id()
4920-
.is_none()
4921-
{
4922-
// No selectable floating panes exist — surface must not be shown
4923-
if let Some(c) = completion.as_mut() {
4924-
c.set_exit_status(1);
4925-
}
49264917
} else {
4927-
self.show_floating_panes();
4928-
if let Some(c) = completion.as_mut() {
4929-
c.set_exit_status(0);
4918+
match self.floating_panes.last_selectable_floating_pane_id() {
4919+
Some(last_selectable_floating_pane_id) => {
4920+
self.show_floating_panes();
4921+
self.floating_panes
4922+
.focus_pane_for_all_clients(last_selectable_floating_pane_id);
4923+
if let Some(c) = completion.as_mut() {
4924+
c.set_exit_status(0);
4925+
}
4926+
},
4927+
None => {
4928+
// No selectable floating panes exist — surface must not be shown
4929+
if let Some(c) = completion.as_mut() {
4930+
c.set_exit_status(1);
4931+
}
4932+
},
49304933
}
49314934
}
49324935
drop(completion);

0 commit comments

Comments
 (0)