summaryrefslogtreecommitdiff
path: root/dev/gui/gui.zig
diff options
context:
space:
mode:
Diffstat (limited to 'dev/gui/gui.zig')
-rw-r--r--dev/gui/gui.zig7
1 files changed, 3 insertions, 4 deletions
diff --git a/dev/gui/gui.zig b/dev/gui/gui.zig
index 9ea813fc..8fd8c24c 100644
--- a/dev/gui/gui.zig
+++ b/dev/gui/gui.zig
@@ -2457,9 +2457,8 @@ const Shell = struct {
/// of their own with no window here; the session loop's
/// (runtime/session.zig), a client's none.
peers: *replica.Peers,
- /// This wait took only a replica's post (its input, its join): the pump
- /// after it reads no new time, so it moves nothing the replicas'
- /// speculations stand on (tui.zig's `mail_only`).
+ /// This wait took nothing but a replica's post, if one (its input, its
+ /// join): the pump after one reads no new time (Peers.heldNow).
mail_only: bool = false,
waited: bool = false,
/// With replica clients, a wait takes one person's input (tui.zig
@@ -3167,7 +3166,7 @@ fn guiNow(ctx: ?*anyopaque) u64 {
const s = shellOf(ctx);
if (s.waited) {
s.waited = false;
- if (s.mail_only and s.peers.count() > 0 and s.core.clock.started) return s.core.clock.now_ns;
+ if (s.peers.heldNow(s.core, s.mail_only)) |held| return held;
}
return s.test_clock orelse s.paced_ns orelse c.SDL_GetTicksNS();
}