+2011-09-27 Leo Liu <sdl.web@gmail.com>
+
+ * ido.el (ido-read-internal): Accept cons cell HIST arg.
+
2011-09-25 Michael Albinus <michael.albinus@gmx.de>
* net/dbus.el (dbus-unregister-object): Don't release services for
;; e.g. the file name may be ignored or joined with ido-current-directory, and
;; the relevant function is called (find-file, write-file, etc).
-(defun ido-read-internal (item prompt history &optional default require-match initial)
+(defun ido-read-internal (item prompt hist &optional default require-match initial)
"Perform the `ido-read-buffer' and `ido-read-file-name' functions.
Return the name of a buffer or file selected.
PROMPT is the prompt to give to the user.
(read-from-minibuffer (ido-make-prompt item prompt)
(prog1 ido-text-init
(setq ido-text-init nil))
- ido-completion-map nil history))))
+ ido-completion-map nil hist))))
(ido-trace "read-from-minibuffer" ido-final-text)
(if (get-buffer ido-completion-buffer)
(kill-buffer ido-completion-buffer))
(t
(setq done t))))))
- (add-to-history (or history 'minibuffer-history) ido-selected)
+ (add-to-history (cond
+ ((consp hist)
+ (or (car hist) 'minibuffer-history))
+ (hist hist)
+ (t 'minibuffer-history))
+ ido-selected)
ido-selected))
(defun ido-edit-input ()