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

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

[elpa] externals/ivy-posframe aea9074 122/195: add ivy-posframe--read ad


From: Feng Shu
Subject: [elpa] externals/ivy-posframe aea9074 122/195: add ivy-posframe--read advice
Date: Sat, 3 Oct 2020 07:11:58 -0400 (EDT)

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

    add ivy-posframe--read advice
---
 ivy-posframe.el | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/ivy-posframe.el b/ivy-posframe.el
index fd9169b..104e700 100644
--- a/ivy-posframe.el
+++ b/ivy-posframe.el
@@ -197,6 +197,11 @@ When 0, no border is showed."
   :group 'ivy-posframe
   :type 'sexp)
 
+(defcustom ivy-posframe-display-functions-alist '((t . ivy-posframe-display))
+  "The `ivy-display-functions-alist' while working ivy-posframe."
+  :group 'ivy-posframe
+  :type 'sexp)
+
 (defcustom ivy-posframe-additional-display-functions nil
   "The additional display functions"
   :group 'ivy-posframe
@@ -472,6 +477,12 @@ selection, non-nil otherwise."
          (append ivy-posframe-height-alist ivy-height-alist)))
     (apply fn args)))
 
+(defun ivy-posframe--read (fn &rest args)
+  "Around advice of FN with AGS."
+  (let ((ivy-display-functions-alist
+         (append ivy-posframe-display-functions-alist 
ivy-display-functions-alist)))
+    (apply fn args)))
+
 ;;; variables
 
 (defvar ivy-posframe-display-function-list
@@ -485,7 +496,8 @@ selection, non-nil otherwise."
 (defvar ivy-posframe-advice-alist
   '((ivy--minibuffer-setup . ivy-posframe--minibuffer-setup)
     (ivy--queue-exhibit    . ivy-posframe--add-prompt)
-    (ivy--height           . ivy-posframe--height)))
+    (ivy--height           . ivy-posframe--height)
+    (ivy-read              . ivy-posframe--read)))
 
 ;;;###autoload
 (define-minor-mode ivy-posframe-mode



reply via email to

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