diff options
| author | Richard M. Stallman | 2004-12-27 22:12:53 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2004-12-27 22:12:53 +0000 |
| commit | e829899894bb613d8d3d9f8e92c5a7ee4edd324a (patch) | |
| tree | 10016c6a8b518e8cdc4d449363db16aa0a0399dd | |
| parent | 95bdef2ed441e60ae9fc0d0b252f008f2121942e (diff) | |
| download | emacs-e829899894bb613d8d3d9f8e92c5a7ee4edd324a.tar.gz emacs-e829899894bb613d8d3d9f8e92c5a7ee4edd324a.zip | |
(undo): Fix previous change.
| -rw-r--r-- | lisp/ChangeLog | 18 | ||||
| -rw-r--r-- | lisp/simple.el | 10 |
2 files changed, 24 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f3f943a52a2..22fac866e38 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2004-12-27 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * simple.el (undo): Fix previous change. | ||
| 4 | |||
| 1 | 2004-12-27 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | 5 | 2004-12-27 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 2 | 6 | ||
| 3 | * term/mac-win.el: Sync with x-win.el. Rearrange the contents. | 7 | * term/mac-win.el: Sync with x-win.el. Rearrange the contents. |
| @@ -6,6 +10,16 @@ | |||
| 6 | 10 | ||
| 7 | 2004-12-27 Richard M. Stallman <rms@gnu.org> | 11 | 2004-12-27 Richard M. Stallman <rms@gnu.org> |
| 8 | 12 | ||
| 13 | * files.el (buffer-save-without-query): New var (buffer-local). | ||
| 14 | (save-some-buffers): Save those buffers first, w/o asking. | ||
| 15 | |||
| 16 | * files.el (insert-directory-ls-version): New variable. | ||
| 17 | (insert-directory): When ls returns an error, test the version | ||
| 18 | number to decide what the return code means. | ||
| 19 | With --dired output format, detect and distinguish lines | ||
| 20 | that are really error messages. | ||
| 21 | (insert-directory-adj-pos): New function. | ||
| 22 | |||
| 9 | * bookmark.el (bookmark-jump): Nice error if BOOKMARK is nil. | 23 | * bookmark.el (bookmark-jump): Nice error if BOOKMARK is nil. |
| 10 | 24 | ||
| 11 | * battery.el (battery-mode-line-format): Remove initial spaces. | 25 | * battery.el (battery-mode-line-format): Remove initial spaces. |
| @@ -59,7 +73,9 @@ | |||
| 59 | 73 | ||
| 60 | * simple.el (undo-list-saved): New variable (buffer-local). | 74 | * simple.el (undo-list-saved): New variable (buffer-local). |
| 61 | (undo): Set and test it. | 75 | (undo): Set and test it. |
| 62 | 76 | (buffer-disable-undo): Moved here from buffer.c. | |
| 77 | Clear out undo-list-saved. | ||
| 78 | |||
| 63 | * international/mule.el (decode-coding-inserted-region): | 79 | * international/mule.el (decode-coding-inserted-region): |
| 64 | Set buffer-undo-list in a correct and optimal way. | 80 | Set buffer-undo-list in a correct and optimal way. |
| 65 | 81 | ||
diff --git a/lisp/simple.el b/lisp/simple.el index 008d52eabc1..b2c6d9df866 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -1263,7 +1263,10 @@ as an argument limits undo to changes within the current region." | |||
| 1263 | (unless (and (eq last-command 'undo) | 1263 | (unless (and (eq last-command 'undo) |
| 1264 | ;; If something (a timer or filter?) changed the buffer | 1264 | ;; If something (a timer or filter?) changed the buffer |
| 1265 | ;; since the previous command, don't continue the undo seq. | 1265 | ;; since the previous command, don't continue the undo seq. |
| 1266 | (eq undo-list-saved buffer-undo-list)) | 1266 | (let ((list buffer-undo-list)) |
| 1267 | (while (eq (car list) nil) | ||
| 1268 | (setq list (cdr list))) | ||
| 1269 | (eq undo-list-saved list))) | ||
| 1267 | (setq undo-in-region | 1270 | (setq undo-in-region |
| 1268 | (if transient-mark-mode mark-active (and arg (not (numberp arg))))) | 1271 | (if transient-mark-mode mark-active (and arg (not (numberp arg))))) |
| 1269 | (if undo-in-region | 1272 | (if undo-in-region |
| @@ -1527,8 +1530,9 @@ is not *inside* the region START...END." | |||
| 1527 | ;; so it had better not do a lot of consing. | 1530 | ;; so it had better not do a lot of consing. |
| 1528 | (setq undo-outer-limit-function 'undo-outer-limit-truncate) | 1531 | (setq undo-outer-limit-function 'undo-outer-limit-truncate) |
| 1529 | (defun undo-outer-limit-truncate (size) | 1532 | (defun undo-outer-limit-truncate (size) |
| 1530 | (if (yes-or-no-p (format "Buffer %s undo info is %d bytes long; discard it? " | 1533 | (if (let (use-dialog-box) |
| 1531 | (buffer-name) size)) | 1534 | (yes-or-no-p (format "Buffer %s undo info is %d bytes long; discard it? " |
| 1535 | (buffer-name) size))) | ||
| 1532 | (progn (setq buffer-undo-list nil) t) | 1536 | (progn (setq buffer-undo-list nil) t) |
| 1533 | nil)) | 1537 | nil)) |
| 1534 | 1538 | ||