summaryrefslogtreecommitdiff
path: root/src/Messages.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-10-24 13:44:56 -0300
committerGabriel Schneider <[email protected]>2026-10-24 15:41:50 -0300
commit578710b72755503ef2ef40a0ae301e608af3e3af (patch)
tree9d7c3574fcff5bbe7f975c802425446b6cc41065 /src/Messages.zig
parentb32447e0b265f25ad7807760956bedf8cf42664d (diff)
downloadpardes-578710b72755503ef2ef40a0ae301e608af3e3af.tar.gz
pardes-578710b72755503ef2ef40a0ae301e608af3e3af.zip
The Del question is a hint: shown on the notice band only after 400 ms of waiting for k or j
Diffstat (limited to 'src/Messages.zig')
-rw-r--r--src/Messages.zig5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Messages.zig b/src/Messages.zig
index 6785bd8a..cb52907a 100644
--- a/src/Messages.zig
+++ b/src/Messages.zig
@@ -582,7 +582,10 @@ pub fn collectNotices(p: *Pardes, pane: *Pane, r: Rect, id: usize) void {
for (pane.msg_older[0..pane.msg_older_len], 0..) |line, i| pane.notices.pushAt(.older, @intCast(i), line.slot);
if (pane.msg_len > 0) pane.notices.pushAt(.message, 0, pane.msg_slot);
if (id == p.active and p.leader_on) pane.notices.push(.leader);
- if (pane.promptText()) |text| if (text.len > 0) pane.notices.push(.prompt);
+ // Del's question shows once its delay is up: answered before that, it
+ // was never there.
+ const del_waiting = pane.prompt == .del_side and pane.question_due_ns > p.now_ns;
+ if (pane.promptText()) |text| if (text.len > 0 and !del_waiting) pane.notices.push(.prompt);
// A pane only has so many rows to give. When they do not all fit the
// LAST ones survive, because the prompt is last and it is the one
// carrying the cursor: a prompt you cannot see is a prompt you type