summaryrefslogtreecommitdiff
path: root/helm-source.el
diff options
context:
space:
mode:
authorThierry Volpiatto <thierry.volpiatto@gmail.com>2017-08-21 06:40:15 +0200
committerThierry Volpiatto <thierry.volpiatto@gmail.com>2017-08-21 06:40:15 +0200
commitef2dc0b08d6acd28237c80abfbe9fd5c6b04c5a9 (patch)
treeb6de87d9bee957214da6951537dc29f202c63aae /helm-source.el
parent47478f5622b906340f4553b5fc7ff2f8eb152405 (diff)
Allow passing a buffer to :data
* helm-source.el (helm--setup-source): Do it.
Diffstat (limited to 'helm-source.el')
-rw-r--r--helm-source.el8
1 files changed, 5 insertions, 3 deletions
diff --git a/helm-source.el b/helm-source.el
index eda58636..ff332bca 100644
--- a/helm-source.el
+++ b/helm-source.el
@@ -966,9 +966,11 @@ an eieio class."
cur-init))
cur-init)
(lambda ()
- (helm-init-candidates-in-buffer
- 'global
- (if (functionp it) (funcall it) it))))))))
+ (if (and (bufferp it) (buffer-live-p it))
+ (helm-candidate-buffer it)
+ (helm-init-candidates-in-buffer
+ 'global
+ (if (functionp it) (funcall it) it)))))))))
(when (slot-value source 'fuzzy-match)
(helm-aif (slot-value source 'search)
(setf (slot-value source 'search)