emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/corfu-doc 122e1f5900 32/95: Only record candidate that


From: ELPA Syncer
Subject: [elpa] externals/corfu-doc 122e1f5900 32/95: Only record candidate that has displayed the doc popup
Date: Tue, 19 Jul 2022 15:58:02 -0400 (EDT)

branch: externals/corfu-doc
commit 122e1f5900a1e27c4aa1dc813c8f936cc3ab8b01
Author: Yuwei Tian <ibluefocus@outlook.com>
Commit: Yuwei Tian <ibluefocus@outlook.com>

    Only record candidate that has displayed the doc popup
---
 corfu-doc.el | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/corfu-doc.el b/corfu-doc.el
index 973df532e4..02e9e8d138 100644
--- a/corfu-doc.el
+++ b/corfu-doc.el
@@ -306,17 +306,18 @@ If this is nil, do not resize corfu doc frame 
automatically."
             (unless (equal cf-frame-edges corfu-doc--cf-frame-edges)
               (apply #'corfu-doc--set-frame-position
                      corfu-doc--frame
-                     (corfu-doc--calculate-doc-frame-position))))
+                     (corfu-doc--calculate-doc-frame-position))
+              (setq corfu-doc--cf-frame-edges cf-frame-edges)))
         ;; fetch documentation and show
         (when-let* ((res (ignore-errors (corfu-doc-fetch-documentation)))
                     (doc (unless (string-empty-p (string-trim res)) res)))
           (corfu-doc--make-frame doc)
           (apply #'corfu-doc--set-frame-position
                  corfu-doc--frame
-                 (corfu-doc--calculate-doc-frame-position))))
+                 (corfu-doc--calculate-doc-frame-position))
+          (setq corfu-doc--candidate candidate)
+          (setq corfu-doc--cf-frame-edges cf-frame-edges)))
       (corfu--echo-refresh)
-      (setq corfu-doc--candidate candidate)
-      (setq corfu-doc--cf-frame-edges cf-frame-edges)
       (setq corfu-doc--window (selected-window)))))
 
 (defun corfu-doc-manually ()



reply via email to

[Prev in Thread] Current Thread [Next in Thread]