summaryrefslogtreecommitdiff
path: root/helm-elisp.el
diff options
context:
space:
mode:
authorThierry Volpiatto <thierry.volpiatto@gmail.com>2016-08-27 10:58:48 +0200
committerThierry Volpiatto <thierry.volpiatto@gmail.com>2016-08-27 10:58:48 +0200
commitc7b3081a64632216b659903d94976b5c61b0f726 (patch)
treeca020e8b92ccac7e75627f1c806dced5b06fa771 /helm-elisp.el
parent161355164ce383acf0713832fec5bcf1afe0fa62 (diff)
Add persistent-action to info-lookup fallback source.
* helm-elisp.el (helm-info-lookup-fallback-source): Do it.
Diffstat (limited to 'helm-elisp.el')
-rw-r--r--helm-elisp.el12
1 files changed, 11 insertions, 1 deletions
diff --git a/helm-elisp.el b/helm-elisp.el
index d92982a0..29b14901 100644
--- a/helm-elisp.el
+++ b/helm-elisp.el
@@ -633,7 +633,13 @@ Filename completion happen if string start after or between a double quote."
(defun helm-info-lookup-fallback-source (candidate)
(let ((sym (helm-symbolify candidate))
src-name fn)
- (cond ((fboundp sym)
+ (cond ((class-p sym)
+ (setq fn #'helm-describe-function
+ src-name "Describe class"))
+ ((generic-p sym)
+ (setq fn #'helm-describe-function
+ src-name "Describe generic function"))
+ ((fboundp sym)
(setq fn #'helm-describe-function
src-name "Describe function"))
((facep sym)
@@ -644,6 +650,10 @@ Filename completion happen if string start after or between a double quote."
src-name "Describe variable")))
(helm-build-sync-source src-name
:candidates (list candidate)
+ :persistent-action (lambda (candidate)
+ (helm-elisp--persistent-help
+ candidate fn))
+ :persistent-help src-name
:nomark t
:action fn)))