diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-19 20:31:32 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-19 20:31:32 -0300 |
| commit | 0db34fbf28e70c8c6a3c6025c0888fc5ec75201c (patch) | |
| tree | f2e288668decded9276ebc45907f16d651b06f9e /core/Handover.zig | |
| parent | 2ab05b536bc3b063666b5aaab497157adc2a9120 (diff) | |
| parent | bf351b62e8843a3d173cedeefa2dd0b8ef4b4392 (diff) | |
| download | pardes-0db34fbf28e70c8c6a3c6025c0888fc5ec75201c.tar.gz pardes-0db34fbf28e70c8c6a3c6025c0888fc5ec75201c.zip | |
integration: a pane's and a view's slot as types, with the regular-expression fixes and the fixes the real loops asked for: pardes-ids (Pane.Id and View.Id through the entries, the events, the effects, the Host table and the device messages) and pardes-merge21, merged without a textual conflict; one call site written since on the old type follows (core/draw.zig: the twin test's file_changed event, .pane = .at(0)); tui core-test 848/991 (143 skipped), shell-test 1027/1030, the window builds; gates in the coordinator's ledger
Co-Authored-By: Claude Fable 5.2 <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'core/Handover.zig')
| -rw-r--r-- | core/Handover.zig | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/core/Handover.zig b/core/Handover.zig index 5347fb95..bcf42c31 100644 --- a/core/Handover.zig +++ b/core/Handover.zig @@ -110,15 +110,15 @@ pub fn begin(h: *Handover, p: *Pardes, carried: Kind, at: usize) void { }, } const said = if (carried == .pane) at else ids[0]; - if (h.flying) return p.setMessage(said, "a pane is already on its way to another window"); + if (h.flying) return p.setMessage(.at(said), "a pane is already on its way to another window"); for (ids[0..n]) |id| { const pane = p.panes[id] orelse return; - if (pane.file == null) return p.setMessage(said, if (pane.isTerminal()) + if (pane.file == null) return p.setMessage(.at(said), if (pane.isTerminal()) "a terminal stays in its window: its shell is this window's child" else "only text panes go to another window, for now"); } - const bytes = dumpCarried(p, carried, at, ids[0..n], h.seq +% 1) catch |err| return p.reportError(said, "handover", err); + const bytes = dumpCarried(p, carried, at, ids[0..n], h.seq +% 1) catch |err| return p.reportError(.at(said), "handover", err); h.deinit(p.gpa); h.bytes = bytes; h.seq +%= 1; @@ -131,7 +131,7 @@ pub fn begin(h: *Handover, p: *Pardes, carried: Kind, at: usize) void { h.serials[i] = pane.serial; h.revisions[i] = pane.file.?.revision; } - p.setMessage(said, if (carried == .pane) "to a new window…" else "the column, to a new window…"); + p.setMessage(.at(said), if (carried == .pane) "to a new window…" else "the column, to a new window…"); p.emit(.{ .hand_over = .{ .seq = h.seq } }); } @@ -171,14 +171,14 @@ pub fn finish(h: *Handover, p: *Pardes, seq: u32, to: []const u8, failure: ?[]co } p.removePane(id, null) catch |err| { kept += 1; - p.reportError(id, "handover", err); + p.reportError(.at(id), "handover", err); }; } if (h.carried == .column) if (layout.columnBySerial(p, h.column_serial)) |c| { if (v.cols[c].n == 0 and v.ncol > 1) layout.dropColumn(p, c); }; layout.compute(p); - p.setMessage(v.active, if (kept == 0) + p.setMessage(.at(v.active), if (kept == 0) std.fmt.bufPrint(&buf, "moved to {s}", .{to}) catch "moved" else std.fmt.bufPrint(&buf, "copied to {s}; edited on the way, kept here too", .{to}) catch "copied"); |
