diff options
| -rw-r--r-- | lisp/ChangeLog | 10 | ||||
| -rw-r--r-- | lisp/server.el | 24 |
2 files changed, 25 insertions, 9 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3067bf36cf9..b17ebc895e3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2006-11-27 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * server.el: Remove spurious * in docstrings. | ||
| 4 | (server-process-filter): Exit from recursive editing before processing | ||
| 5 | a new request. | ||
| 6 | |||
| 1 | 2006-11-27 J.D. Smith <jdsmith@as.arizona.edu> | 7 | 2006-11-27 J.D. Smith <jdsmith@as.arizona.edu> |
| 2 | 8 | ||
| 3 | * progmodes/hideshow.el (hs-already-hidden-p): Move to end of | 9 | * progmodes/hideshow.el (hs-already-hidden-p): Move to end of |
| @@ -97,8 +103,8 @@ | |||
| 97 | 103 | ||
| 98 | 2006-11-25 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | 104 | 2006-11-25 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> |
| 99 | 105 | ||
| 100 | * progmodes/cc-vars.el (c-backslash-column): Mention | 106 | * progmodes/cc-vars.el (c-backslash-column): |
| 101 | c-backslash-max-column in documentation for c-backslash-column. | 107 | Mention c-backslash-max-column in documentation for c-backslash-column. |
| 102 | 108 | ||
| 103 | 2006-11-24 Lars Hansen <larsh@soem.dk> | 109 | 2006-11-24 Lars Hansen <larsh@soem.dk> |
| 104 | 110 | ||
diff --git a/lisp/server.el b/lisp/server.el index bcb79d6b9ac..3ae585e9bc4 100644 --- a/lisp/server.el +++ b/lisp/server.el | |||
| @@ -113,23 +113,23 @@ If set, the server accepts remote connections; otherwise it is local." | |||
| 113 | (put 'server-auth-dir 'risky-local-variable t) | 113 | (put 'server-auth-dir 'risky-local-variable t) |
| 114 | 114 | ||
| 115 | (defcustom server-raise-frame t | 115 | (defcustom server-raise-frame t |
| 116 | "*If non-nil, raise frame when switching to a buffer." | 116 | "If non-nil, raise frame when switching to a buffer." |
| 117 | :group 'server | 117 | :group 'server |
| 118 | :type 'boolean | 118 | :type 'boolean |
| 119 | :version "22.1") | 119 | :version "22.1") |
| 120 | 120 | ||
| 121 | (defcustom server-visit-hook nil | 121 | (defcustom server-visit-hook nil |
| 122 | "*Hook run when visiting a file for the Emacs server." | 122 | "Hook run when visiting a file for the Emacs server." |
| 123 | :group 'server | 123 | :group 'server |
| 124 | :type 'hook) | 124 | :type 'hook) |
| 125 | 125 | ||
| 126 | (defcustom server-switch-hook nil | 126 | (defcustom server-switch-hook nil |
| 127 | "*Hook run when switching to a buffer for the Emacs server." | 127 | "Hook run when switching to a buffer for the Emacs server." |
| 128 | :group 'server | 128 | :group 'server |
| 129 | :type 'hook) | 129 | :type 'hook) |
| 130 | 130 | ||
| 131 | (defcustom server-done-hook nil | 131 | (defcustom server-done-hook nil |
| 132 | "*Hook run when done editing a buffer for the Emacs server." | 132 | "Hook run when done editing a buffer for the Emacs server." |
| 133 | :group 'server | 133 | :group 'server |
| 134 | :type 'hook) | 134 | :type 'hook) |
| 135 | 135 | ||
| @@ -149,7 +149,7 @@ When a buffer is marked as \"done\", it is removed from this list.") | |||
| 149 | (put 'server-buffer-clients 'permanent-local t) | 149 | (put 'server-buffer-clients 'permanent-local t) |
| 150 | 150 | ||
| 151 | (defcustom server-window nil | 151 | (defcustom server-window nil |
| 152 | "*Specification of the window to use for selecting Emacs server buffers. | 152 | "Specification of the window to use for selecting Emacs server buffers. |
| 153 | If nil, use the selected window. | 153 | If nil, use the selected window. |
| 154 | If it is a function, it should take one argument (a buffer) and | 154 | If it is a function, it should take one argument (a buffer) and |
| 155 | display and select it. A common value is `pop-to-buffer'. | 155 | display and select it. A common value is `pop-to-buffer'. |
| @@ -168,14 +168,14 @@ Only programs can do so." | |||
| 168 | (function :tag "Other function"))) | 168 | (function :tag "Other function"))) |
| 169 | 169 | ||
| 170 | (defcustom server-temp-file-regexp "^/tmp/Re\\|/draft$" | 170 | (defcustom server-temp-file-regexp "^/tmp/Re\\|/draft$" |
| 171 | "*Regexp matching names of temporary files. | 171 | "Regexp matching names of temporary files. |
| 172 | These are deleted and reused after each edit by the programs that | 172 | These are deleted and reused after each edit by the programs that |
| 173 | invoke the Emacs server." | 173 | invoke the Emacs server." |
| 174 | :group 'server | 174 | :group 'server |
| 175 | :type 'regexp) | 175 | :type 'regexp) |
| 176 | 176 | ||
| 177 | (defcustom server-kill-new-buffers t | 177 | (defcustom server-kill-new-buffers t |
| 178 | "*Whether to kill buffers when done with them. | 178 | "Whether to kill buffers when done with them. |
| 179 | If non-nil, kill a buffer unless it already existed before editing | 179 | If non-nil, kill a buffer unless it already existed before editing |
| 180 | it with Emacs server. If nil, kill only buffers as specified by | 180 | it with Emacs server. If nil, kill only buffers as specified by |
| 181 | `server-temp-file-regexp'. | 181 | `server-temp-file-regexp'. |
| @@ -403,6 +403,16 @@ PROC is the server process. Format of STRING is \"PATH PATH PATH... \\n\"." | |||
| 403 | (when prev | 403 | (when prev |
| 404 | (setq string (concat prev string)) | 404 | (setq string (concat prev string)) |
| 405 | (process-put proc :previous-string nil))) | 405 | (process-put proc :previous-string nil))) |
| 406 | (when (> (recursion-depth) 0) | ||
| 407 | ;; We're inside a minibuffer already, so if the emacs-client is trying | ||
| 408 | ;; to open a frame on a new display, we might end up with an unusable | ||
| 409 | ;; frame because input from that display will be blocked (until exiting | ||
| 410 | ;; the minibuffer). Better exit this minibuffer right away. | ||
| 411 | ;; Similarly with recursive-edits such as the splash screen. | ||
| 412 | (process-put proc :previous-string string) | ||
| 413 | (run-with-timer 0 nil (lexical-let ((proc proc)) | ||
| 414 | (lambda () (server-process-filter proc "")))) | ||
| 415 | (top-level)) | ||
| 406 | ;; If the input is multiple lines, | 416 | ;; If the input is multiple lines, |
| 407 | ;; process each line individually. | 417 | ;; process each line individually. |
| 408 | (while (string-match "\n" string) | 418 | (while (string-match "\n" string) |