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

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

[elpa] externals/ivy-posframe 19cc919 110/195: use function-alist instea


From: Feng Shu
Subject: [elpa] externals/ivy-posframe 19cc919 110/195: use function-alist instead of display-functions
Date: Sat, 3 Oct 2020 07:11:55 -0400 (EDT)

branch: externals/ivy-posframe
commit 19cc9199e0d0098921c685c03b6898ea30436790
Author: conao3 <conao3@gmail.com>
Commit: conao3 <conao3@gmail.com>

    use function-alist instead of display-functions
---
 ivy-posframe.el | 15 +++++----------
 1 file changed, 5 insertions(+), 10 deletions(-)

diff --git a/ivy-posframe.el b/ivy-posframe.el
index 7204c72..7702bcb 100644
--- a/ivy-posframe.el
+++ b/ivy-posframe.el
@@ -434,15 +434,6 @@ selection, non-nil otherwise."
 
 ;;; variables
 
-(defvar ivy-posframe-display-functions
-  '(ivy-posframe-display
-    ivy-posframe-display-at-window-center
-    ivy-posframe-display-at-frame-center
-    ivy-posframe-display-at-window-bottom-left
-    ivy-posframe-display-at-frame-bottom-left
-    ivy-posframe-display-at-frame-bottom-window-center
-    ivy-posframe-display-at-point))
-
 (defvar ivy-posframe-advice-alist
   '((ivy--minibuffer-setup . ivy-posframe--minibuffer-setup)
     (ivy--queue-exhibit    . ivy-posframe--add-prompt)))
@@ -460,7 +451,11 @@ selection, non-nil otherwise."
   :global t
   :lighter " ivy-pf"
   :group 'ivy-posframe
-  (let ((fncs ivy-posframe-display-functions)
+  (let ((fncs (append (mapcar
+                       (lambda (elm) (intern (format 
"ivy-posframe-display-at-%s" (car elm))))
+                       ivy-posframe-display-functions-alist)
+                      '(ivy-posframe-display
+                        ivy-posframe-display-at-frame-bottom-window-center)))
         (advs ivy-posframe-advice-alist)
         (keys ivy-posframe-keybind-list))
     (if ivy-posframe-mode



reply via email to

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