summaryrefslogtreecommitdiff
path: root/src/tape.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-10-30 21:00:30 -0300
committerGabriel Schneider <[email protected]>2026-10-30 21:53:52 -0300
commitd00c40694dc239854263616f710b4a197d25d145 (patch)
tree3e7a980510e6c37507e0b60f1632cefc67d1c364 /src/tape.zig
parente6a114eed043dd1ca50be1cab912662fa9150fda (diff)
downloadpardes-d00c40694dc239854263616f710b4a197d25d145.tar.gz
pardes-d00c40694dc239854263616f710b4a197d25d145.zip
views: a client that joins again has its own view back, layout, focus and the panes opened in it: an Upgrade's clients and one whose bye says it joins again (a divergence's, wire 19's `bye.again`) leave their view kept for them (`views_away`, digested and dumped, so an Upgrade's new build has it; taped `awayView`), the client names it in its next hello (`Hello.view`, handed on by the daemon with the connection) and its join takes it back (taped `rejoinView`) rather than a copy of the session's; the live view is never a kept one, `views.count` counts the others, and a join with every view taken lets one go (every Upgrade made each client's own panes leave its view: the hunt's 80 ms cell lost `+Search` and `+New`)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/tape.zig')
-rw-r--r--src/tape.zig4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tape.zig b/src/tape.zig
index 4759d598..74576eed 100644
--- a/src/tape.zig
+++ b/src/tape.zig
@@ -67,6 +67,8 @@ pub const Input = union(enum) {
open_view,
close_view: u8,
leave_view: u8,
+ away_view: u8,
+ rejoin_view: u8,
to_view: u8,
/// What a window says of its font and its opacity (gui.zig).
take_font_request,
@@ -630,6 +632,8 @@ pub const Tape = struct {
.open_view => _ = p.openView(),
.close_view => |k| p.closeView(k),
.leave_view => |k| p.leaveView(k),
+ .away_view => |k| p.awayView(k),
+ .rejoin_view => |k| _ = p.rejoinView(k),
.to_view => |k| p.toView(k),
.take_font_request => _ = p.takeFontRequest(),
.observe_font => |f| _ = p.observeFont(f.name, f.size, f.unit),