summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1993-08-12 22:21:12 +0000
committerRichard M. Stallman <rms@gnu.org>1993-08-12 22:21:12 +0000
commit324710caf596ebf599be0376a53dfd4470400503 (patch)
treef70d07282e38b6d6c2381ceef9e342ad20519ec9
parent3070929adb33aa100d7a99f8d72d93fb08c45b9b (diff)
downloademacs-324710caf596ebf599be0376a53dfd4470400503.tar.gz
(mouse-choose-completion): Really go to minibuffer; no save-excursion.
-rw-r--r--lisp/mouse.el19
1 files changed, 9 insertions, 10 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el
index d59bc57e74d..f15cc0f2bc8 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -880,16 +880,15 @@ and selects that window."
(let ((beg (point)))
(skip-chars-forward "^ \t\n")
(setq choice (buffer-substring beg (point))))))
- (save-excursion
- (set-buffer (window-buffer (minibuffer-window)))
- (goto-char (max (point-min) (- (point-max) (length choice))))
- (while (and (not (eobp))
- (let ((tail (buffer-substring (point) (point-max))))
- (not (string= tail (substring choice 0 (length tail))))))
- (forward-char 1))
- (insert choice)
- (delete-region (point) (point-max))
- (minibuffer-complete-and-exit))))
+ (set-buffer (window-buffer (minibuffer-window)))
+ (goto-char (max (point-min) (- (point-max) (length choice))))
+ (while (and (not (eobp))
+ (let ((tail (buffer-substring (point) (point-max))))
+ (not (string= tail (substring choice 0 (length tail))))))
+ (forward-char 1))
+ (insert choice)
+ (delete-region (point) (point-max))
+ (minibuffer-complete-and-exit)))
;; Font selection.