[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/minuet 8b9ea6ff1c 08/97: fix: use idle timer and fix bu
From: |
ELPA Syncer |
Subject: |
[elpa] externals/minuet 8b9ea6ff1c 08/97: fix: use idle timer and fix buffer changing check for auto-suggestion. |
Date: |
Mon, 24 Mar 2025 18:59:10 -0400 (EDT) |
branch: externals/minuet
commit 8b9ea6ff1cb05840bee7daf31a95d4a3ad105537
Author: Milan Glacier <dev@milanglacier.com>
Commit: Milan Glacier <dev@milanglacier.com>
fix: use idle timer and fix buffer changing check for auto-suggestion.
---
minuet.el | 21 +++++++++++----------
1 file changed, 11 insertions(+), 10 deletions(-)
diff --git a/minuet.el b/minuet.el
index 9d6e79a0f9..79253c578d 100644
--- a/minuet.el
+++ b/minuet.el
@@ -988,16 +988,17 @@ to be called when completion items arrive."
(when minuet--debounce-timer
(cancel-timer minuet--debounce-timer))
(setq minuet--debounce-timer
- (run-with-timer
- minuet-auto-suggestion-debounce-delay nil
- (lambda ()
- (when (and (eq (window-buffer (selected-window))
(current-buffer))
- (or (null minuet--auto-last-point)
- (not (eq minuet--auto-last-point (point))))
- (not (run-hook-with-args-until-success
'minuet-auto-suggestion-block-functions)))
- (setq minuet--last-auto-suggestion-time (current-time)
- minuet--auto-last-point (point))
- (minuet-show-suggestion)))))))
+ (let ((buffer (current-buffer)))
+ (run-with-idle-timer
+ minuet-auto-suggestion-debounce-delay nil
+ (lambda ()
+ (when (and (eq buffer (current-buffer))
+ (or (null minuet--auto-last-point)
+ (not (eq minuet--auto-last-point
(point))))
+ (not (run-hook-with-args-until-success
'minuet-auto-suggestion-block-functions)))
+ (setq minuet--last-auto-suggestion-time
(current-time)
+ minuet--auto-last-point (point))
+ (minuet-show-suggestion))))))))
(defun minuet--cleanup-auto-suggestion ()
"Clean up auto-suggestion timers and hooks."
- [elpa] branch externals/minuet created (now 55f6527b2b), ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 4dbbceaad4 01/97: initial commit., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet ef057e07b5 03/97: chore: add license., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 8b9ea6ff1c 08/97: fix: use idle timer and fix buffer changing check for auto-suggestion.,
ELPA Syncer <=
- [elpa] externals/minuet bdf181c66f 12/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet a4f6ce017e 10/97: fix: clean up code., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 64c24f303e 13/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 67ca0959d0 15/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet bffeba26d8 14/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 49502af28f 19/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 36d3b5348c 17/97: chore: update editor config., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 32085f5efc 24/97: fix: fix api-key fetching for OpenAI provider., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet 2248735858 26/97: doc: update README., ELPA Syncer, 2025/03/24
- [elpa] externals/minuet b106155b80 37/97: chore: deploy melpazoid for github CI., ELPA Syncer, 2025/03/24