aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/replace.el
diff options
context:
space:
mode:
authorJuri Linkov2005-11-28 19:59:16 +0000
committerJuri Linkov2005-11-28 19:59:16 +0000
commit6c6605b2cf27340ed455d20de6b289beea1a62d7 (patch)
tree0208f54c4924e9d7427ea41d711e620594129315 /lisp/replace.el
parent7e1d31d4604a0525afd6b25cb1bf31bd23fe9db9 (diff)
downloademacs-6c6605b2cf27340ed455d20de6b289beea1a62d7.tar.gz
emacs-6c6605b2cf27340ed455d20de6b289beea1a62d7.zip
(occur-mode-mouse-goto): Pop, don't switch.
(occur-mode-goto-occurrence): Let-bind same-window-buffer-names and same-window-regexps. (occur-next-error): Don't move point for arg 0.
Diffstat (limited to 'lisp/replace.el')
-rw-r--r--lisp/replace.el11
1 files changed, 8 insertions, 3 deletions
diff --git a/lisp/replace.el b/lisp/replace.el
index f269baef9f1..57326d08ef2 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -755,7 +755,9 @@ Alternatively, click \\[occur-mode-mouse-goto] on an item to go to it.
755 (save-excursion 755 (save-excursion
756 (goto-char (posn-point (event-end event))) 756 (goto-char (posn-point (event-end event)))
757 (setq pos (occur-mode-find-occurrence)))) 757 (setq pos (occur-mode-find-occurrence))))
758 (switch-to-buffer-other-window (marker-buffer pos)) 758 (let (same-window-buffer-names
759 same-window-regexps)
760 (pop-to-buffer (marker-buffer pos)))
759 (goto-char pos))) 761 (goto-char pos)))
760 762
761(defun occur-mode-find-occurrence () 763(defun occur-mode-find-occurrence ()
@@ -769,7 +771,9 @@ Alternatively, click \\[occur-mode-mouse-goto] on an item to go to it.
769(defun occur-mode-goto-occurrence () 771(defun occur-mode-goto-occurrence ()
770 "Go to the occurrence the current line describes." 772 "Go to the occurrence the current line describes."
771 (interactive) 773 (interactive)
772 (let ((pos (occur-mode-find-occurrence))) 774 (let ((pos (occur-mode-find-occurrence))
775 same-window-buffer-names
776 same-window-regexps)
773 (pop-to-buffer (marker-buffer pos)) 777 (pop-to-buffer (marker-buffer pos))
774 (goto-char pos))) 778 (goto-char pos)))
775 779
@@ -832,7 +836,8 @@ Compatibility function for \\[next-error] invocations."
832 836
833 (goto-char (cond (reset (point-min)) 837 (goto-char (cond (reset (point-min))
834 ((< argp 0) (line-beginning-position)) 838 ((< argp 0) (line-beginning-position))
835 ((line-end-position)))) 839 ((> argp 0) (line-end-position))
840 ((point))))
836 (occur-find-match 841 (occur-find-match
837 (abs argp) 842 (abs argp)
838 (if (> 0 argp) 843 (if (> 0 argp)