]> code.delx.au - gnu-emacs/blobdiff - lisp/isearch.el
(isearch-done): Move point (for small window)
[gnu-emacs] / lisp / isearch.el
index 071e48c9634a5cf262b41fcebe89e48f7f4d0e97..77ce1aeb6b37444a9b65cc5ff5d41ad50094bc86 100644 (file)
@@ -4,7 +4,7 @@
 
 ;; Author: Daniel LaLiberte <liberte@cs.uiuc.edu>
 
-;; |$Date: 1993/06/13 21:43:15 $|$Revision: 1.43 $
+;; |$Date: 1993/07/15 03:46:02 $|$Revision: 1.46 $
 
 ;; This file is not yet part of GNU Emacs, but it is based almost
 ;; entirely on isearch.el which is part of GNU Emacs.
@@ -584,21 +584,21 @@ is treated as a regexp.  See \\[isearch-forward] for more info."
     (if isearch-window-configuration
        (set-window-configuration isearch-window-configuration))
 
+    (if isearch-small-window
+       (goto-char found-point)
+      ;; Exiting the save-window-excursion clobbers window-start; restore it.
+      (set-window-start (selected-window) found-start t)))
+
     ;; If there was movement, mark the starting position.
     ;; Maybe should test difference between and set mark iff > threshold.
     (if (/= (point) isearch-opoint)
        (progn
          (push-mark isearch-opoint t)
-         (if transient-mark-mode
-             (setq mark-active nil))
+         (deactivate-mark)
          (or executing-macro (> (minibuffer-depth) 0)
              (message "Mark saved where search started")))
       ;; (message "") why is this needed?
       )
-    (if isearch-small-window
-       (goto-char found-point)
-      ;; Exiting the save-window-excursion clobbers window-start; restore it.
-      (set-window-start (selected-window) found-start t)))
 
   (setq isearch-mode nil)
   (set-buffer-modified-p (buffer-modified-p))  ;; update modeline
@@ -676,7 +676,7 @@ If first char entered is \\[isearch-yank-word], then do word search instead."
   ;; Editing doesn't back up the search point.  Should it?
   (interactive)
   (condition-case err
-      (let (isearch-nonincremental     ; should search nonincrementally?
+      (let ((isearch-nonincremental isearch-nonincremental)
 
            ;; Locally bind all isearch global variables to protect them
            ;; from recursive isearching.