[Top][All Lists]

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

[elpa] master 2b974b4 139/184: ivy.el (ivy-update-fns-alist): New defcus

From: Oleh Krehel
Subject: [elpa] master 2b974b4 139/184: ivy.el (ivy-update-fns-alist): New defcustom
Date: Wed, 16 Oct 2019 13:15:09 -0400 (EDT)

branch: master
commit 2b974b48219ead46abee726160c1c06442e963b3
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>

    ivy.el (ivy-update-fns-alist): New defcustom
    Fixes #2188
 ivy.el | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/ivy.el b/ivy.el
index f09e88b..a85e8fa 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1892,6 +1892,15 @@ Examples: `toggle-input-method', (lambda () (insert 
\"^\")), etc.
 May supersede `ivy-initial-inputs-alist'."
   :type '(alist :key-type symbol :value-type function))
+(defcustom ivy-update-fns-alist nil
+  "An alist associating commands to their :update-fn values."
+  :type '(alist
+          :key-type symbol
+          :value-type
+          (radio
+           (const :tag "Off" nil)
+           (const :tag "Call action on change" auto))))
 (defcustom ivy-sort-max-size 30000
   "Sorting won't be done for collections larger than this."
   :type 'integer)
@@ -2028,6 +2037,7 @@ customizations apply to the current completion session."
                     (not (window-minibuffer-p)))
             (ivy-alist-setting ivy-display-functions-alist caller)))
+    (setq update-fn (ivy-alist-setting ivy-update-fns-alist caller))
     (setq ivy-last
            :prompt prompt

reply via email to

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