From 8939e3514b38442e5d1fbe1e917bcaad9c1d7d14 Mon Sep 17 00:00:00 2001 From: NeilBrown Date: Fri, 21 Jul 2023 12:33:24 +1000 Subject: [PATCH] make: possibly fix problem with not always following. This is just a guess, but maybe this is why make sometimes doesn't follow the output properly. Signed-off-by: NeilBrown --- DOC/TODO.md | 2 +- python/lib-make.py | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/DOC/TODO.md b/DOC/TODO.md index 375b752a..6001c3a1 100644 --- a/DOC/TODO.md +++ b/DOC/TODO.md @@ -14,7 +14,7 @@ the file. - [X] when find-file dialog shifts left, it doesn't shift back until cursor is v.close to left, even when the rest of the line is blank - [X] line-count in make output is weird. Second line can be thousands -- [ ] Make sometimes doesn't follow output, though usually it does +- [X] Make sometimes doesn't follow output, though usually it does - [ ] If dynamic-complete only finds one completion, does it still want a menu? - [ ] When merge makes a change, highlight the new content. diff --git a/python/lib-make.py b/python/lib-make.py index 7ff1de3d..0c0115f5 100644 --- a/python/lib-make.py +++ b/python/lib-make.py @@ -563,6 +563,7 @@ class MakeViewerPane(edlib.Pane): edlib.Pane.__init__(self, focus) self.call("doc:request:doc:replaced") self.call("doc:request:make-set-match") + self.call("doc:request:make-close") self.may_follow = True # I think I want to start following, but if there are already matches, # I really want to go to one of those... let's try this. @@ -575,6 +576,12 @@ class MakeViewerPane(edlib.Pane): self.may_follow = (num == 1) return 1 + def handle_make_close(self, key, **a): + "handle:make-close" + # A new doc, so I want to follow + self.may_follow = True + return 1 + def handle_enter(self, key, focus, mark, **a): "handle-list/K:Enter/K-o" dname = focus["doc-name"] -- 2.39.5