summaryrefslogtreecommitdiff
path: root/lisp/ido.el
diff options
context:
space:
mode:
authorKim F. Storm <storm@cua.dk>2008-09-04 10:01:45 +0000
committerKim F. Storm <storm@cua.dk>2008-09-04 10:01:45 +0000
commit7d046dbbac5a3e38093b90fe49e77c3323369615 (patch)
tree50077e6338cbcbe0c18df4fe7715dff7f2c5f181 /lisp/ido.el
parent922649a9dc62f7634ef9a4b582c1c15c0afbad87 (diff)
downloademacs-7d046dbbac5a3e38093b90fe49e77c3323369615.tar.gz
(ido-buffer-internal, ido-file-internal): Pass on other-window
and other-frame methods when switching between file and buffer modes.
Diffstat (limited to 'lisp/ido.el')
-rw-r--r--lisp/ido.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/ido.el b/lisp/ido.el
index fd0e6b2f7aa..dbf6cb87801 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -2161,7 +2161,9 @@ If cursor is not at the end of the user input, move to end of input."
(cond
((eq ido-exit 'find-file)
- (ido-file-internal ido-default-file-method nil nil nil nil ido-text))
+ (ido-file-internal
+ (if (memq method '(other-window other-frame)) method ido-default-file-method)
+ nil nil nil nil ido-text))
((eq ido-exit 'insert-file)
(ido-file-internal 'insert 'insert-file nil "Insert file: " nil ido-text 'ido-enter-insert-buffer))
@@ -2317,7 +2319,9 @@ If cursor is not at the end of the user input, move to end of input."
(call-interactively this-command)))
((eq ido-exit 'switch-to-buffer)
- (ido-buffer-internal ido-default-buffer-method nil nil nil ido-text))
+ (ido-buffer-internal
+ (if (memq method '(other-window other-frame)) method ido-default-buffer-method)
+ nil nil nil ido-text))
((eq ido-exit 'insert-buffer)
(ido-buffer-internal 'insert 'insert-buffer "Insert buffer: " nil ido-text 'ido-enter-insert-file))