comparison lisp/server.el @ 76648:ab479de41b29

(server-process-filter): Cancel any pending isearch.
author Juanma Barranquero <lekktu@gmail.com>
date Wed, 21 Mar 2007 12:02:32 +0000
parents 09eed2796001
children 9355f9b7bbff 79cdba83d213 738ce3540ffb c0409ee15cee
comparison
equal deleted inserted replaced
76647:a91fecca26d3 76648:ab479de41b29
412 ;; Similarly with recursive-edits such as the splash screen. 412 ;; Similarly with recursive-edits such as the splash screen.
413 (process-put proc :previous-string string) 413 (process-put proc :previous-string string)
414 (run-with-timer 0 nil (lexical-let ((proc proc)) 414 (run-with-timer 0 nil (lexical-let ((proc proc))
415 (lambda () (server-process-filter proc "")))) 415 (lambda () (server-process-filter proc ""))))
416 (top-level)) 416 (top-level))
417 (condition-case nil
418 ;; If we're running isearch, we must abort it to allow Emacs to
419 ;; display the buffer and switch to it.
420 (mapc #'(lambda (buffer)
421 (with-current-buffer buffer
422 (when (bound-and-true-p isearch-mode)
423 (isearch-cancel))))
424 (buffer-list))
425 ;; Signaled by isearch-cancel
426 (quit (message nil)))
417 ;; If the input is multiple lines, 427 ;; If the input is multiple lines,
418 ;; process each line individually. 428 ;; process each line individually.
419 (while (string-match "\n" string) 429 (while (string-match "\n" string)
420 (let ((request (substring string 0 (match-beginning 0))) 430 (let ((request (substring string 0 (match-beginning 0)))
421 (coding-system (and default-enable-multibyte-characters 431 (coding-system (and default-enable-multibyte-characters