This commit is contained in:
João Távora 2012-07-17 04:11:22 +01:00
parent aae62703f4
commit 7e39aa3e56
Notes: Noam Postavsky 2016-05-01 17:39:36 -04:00
Only use ido completion if ido-mode is enabled

In Emacs 23, ido-completing-read behaves poorly if ido-mode is not
enabled.

* yasnippet.el (yas/ido-prompt): In Emacs 23, check if ido-mode is
non-nil.

View File

@ -1588,7 +1588,9 @@ TEMPLATES is a list of `yas/template'."
(keyboard-quit))))
(defun yas/ido-prompt (prompt choices &optional display-fn)
(when (fboundp 'ido-completing-read)
(when (and (fboundp 'ido-completing-read)
(or (>= emacs-major-version 24)
ido-mode))
(yas/completing-prompt prompt choices display-fn #'ido-completing-read)))
(eval-when-compile (require 'dropdown-list nil t))