diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-18 18:29:55 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-18 19:13:20 -0300 |
| commit | 6174a6fe323ecc57fca72282d0c97d24516f4325 (patch) | |
| tree | 0dff7685968669ab1b108fa9b3c4e60e4ac49c60 /src/gui | |
| parent | 41f665c986886790e474bef78928f4b0d3b05c21 (diff) | |
| parent | 28921f1f793938b2d40a1a8fee43d3b1b0f7c4d2 (diff) | |
| download | pardes-6174a6fe323ecc57fca72282d0c97d24516f4325.tar.gz pardes-6174a6fe323ecc57fca72282d0c97d24516f4325.zip | |
integration: the client path's round 5 (the soak with addons, a session clock and Detach; a replica joined from a dump announcing no panes; a digest compared only where one is due; a window client's size posted once) with the Shadow path deleted: one conflict, Kind.zig's Slot.free (the used list freed with the slot's allocator, and no shadow to free); on Zig 0.17.1: replicas with five clients and addons loaded: diverged 0, unequal 0, deltas checked/wrong 1807/0, 2085/0, 1912/0, quiet checks 436/0, 593/0, 738/0, digests compared in 849 of 14549, 958 of 14517 and 1060 of 15638 units; tui core-test 820/961 (141 skipped), shell-test 996/999, behaviour-test 274/274 and its replay 20 seeds with 0 failures, pane-test 183/184; gui frame corpus 77/77 Debug and ReleaseFast against mbase171, unit-test 1593/1597, the tui build has no SDL symbol, the perf window +0.180% (reported: spread 0.81%); known open: a PDF pane makes clients diverge when another client presses a key in it (the soak opens none)
Co-Authored-By: Claude Fable 5.2 <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'src/gui')
| -rw-r--r-- | src/gui/gui.zig | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/gui/gui.zig b/src/gui/gui.zig index a8816494..4f6a58c2 100644 --- a/src/gui/gui.zig +++ b/src/gui/gui.zig @@ -1216,6 +1216,10 @@ const Client = struct { inbox: std.ArrayListUnmanaged(replica.Said) = .empty, taken: std.ArrayListUnmanaged(replica.Said) = .empty, ended: bool = false, + /// The size the window last posted while its view is not that size + /// yet (the session has not taken it, or speculation stopped at it): + /// posted once, not again each pass while it waits. + posted: ?@FieldType(pardes.Event, "resize") = null, fn deinit(cl: *Client) void { cl.pending.deinit(cl.gpa); @@ -1330,7 +1334,11 @@ const OwnView = struct { if (scrollRows(g, v.in, v.s.gpa)) v.s.client.?.link.dirty = true; if (fitTaglineFont(g, core.settings.font.tagline_percent)) v.s.client.?.link.dirty = true; const geom = windowCells(g); - if (resizeOf(core.view(), geom.cols, geom.rows, g.cell_w, g.cell_h, g.tagline_width, g.tagline_height)) |ev| v.in.post(ev); + const cl = v.s.client.?; + if (resizeOf(core.view(), geom.cols, geom.rows, g.cell_w, g.cell_h, g.tagline_width, g.tagline_height)) |ev| { + if (cl.posted == null or !std.meta.eql(cl.posted.?, ev.resize)) v.in.post(ev); + cl.posted = ev.resize; + } else cl.posted = null; if (v.pointer) refreshPresentedPointer(g, v.in); runDemo(g, v.in, core); if (v.s.test_mode) { @@ -1424,6 +1432,7 @@ fn clientSession(init: std.process.Init, g: *Gui, opts_in: pardes.Options, test_ g.hit_core = core; frame_probe = &core.frames; link.reset(r, &joined); + client.posted = null; client.ended = false; // ponytail: why it joined again is the window's title (and its // log) until a key, where a terminal's client draws it over its |
