summaryrefslogtreecommitdiff
path: root/core/panes.zig
diff options
context:
space:
mode:
Diffstat (limited to 'core/panes.zig')
-rw-r--r--core/panes.zig3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/panes.zig b/core/panes.zig
index c11fdc94..1a27b238 100644
--- a/core/panes.zig
+++ b/core/panes.zig
@@ -1510,6 +1510,9 @@ pub fn removePane(p: *Pardes, id: usize, to: ?usize) error{OutOfMemory}!void {
try p.removePane(k, id);
layout.compute(p);
};
+ // A held pane's reader is its tether: it closes with it (pick-ui
+ // SPEC ยง11), its rows going where a closed pane's go.
+ if (Trail.readerOf(p, pane)) |r| try p.removePane(r, null);
// A docked pane's rows go back to its owner and nobody else.
const owner = layout.ownerOf(p, id);
const place = layout.findPane(p, id);