diff options
| author | Kim F. Storm | 2002-06-21 13:51:05 +0000 |
|---|---|---|
| committer | Kim F. Storm | 2002-06-21 13:51:05 +0000 |
| commit | 1c62c12fbf9ffd25acbe44cb451b8de3fb675c09 (patch) | |
| tree | b2b6eeaebea3c2b6ad10008093188d669856bd2f | |
| parent | 83cfd18fc83af8f94a7c828e86df44915020e04d (diff) | |
| download | emacs-1c62c12fbf9ffd25acbe44cb451b8de3fb675c09.tar.gz emacs-1c62c12fbf9ffd25acbe44cb451b8de3fb675c09.zip | |
(cua--prefix-arg): Make register prefixes
work again. Corrected error in check for C-u initiated prefix.
| -rw-r--r-- | lisp/emulation/cua-base.el | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/lisp/emulation/cua-base.el b/lisp/emulation/cua-base.el index f7887575521..2c7d3ddf0b1 100644 --- a/lisp/emulation/cua-base.el +++ b/lisp/emulation/cua-base.el | |||
| @@ -653,17 +653,19 @@ Repeating prefix key when region is active works as a single prefix key." | |||
| 653 | (defun cua--prefix-arg (arg) | 653 | (defun cua--prefix-arg (arg) |
| 654 | (setq cua--register | 654 | (setq cua--register |
| 655 | (and cua-enable-register-prefix | 655 | (and cua-enable-register-prefix |
| 656 | (integerp (this-command-keys)) | ||
| 657 | (cond ((eq cua-enable-register-prefix 'not-ctrl-u) | ||
| 658 | (not (= (aref (this-command-keys) 0) ?\C-u))) | ||
| 659 | ((eq cua-enable-register-prefix 'ctrl-u-only) | ||
| 660 | (= (aref (this-command-keys) 0) ?\C-u)) | ||
| 661 | (t t)) | ||
| 662 | (integerp arg) (>= arg 0) (< arg 10) | 656 | (integerp arg) (>= arg 0) (< arg 10) |
| 657 | (let* ((prefix (aref (this-command-keys) 0)) | ||
| 658 | (ctrl-u-prefix (and (integerp prefix) | ||
| 659 | (= prefix ?\C-u))))) | ||
| 660 | (cond | ||
| 661 | ((eq cua-enable-register-prefix 'not-ctrl-u) | ||
| 662 | (not ctrl-u-prefix)) | ||
| 663 | ((eq cua-enable-register-prefix 'ctrl-u-only) | ||
| 664 | ctrl-u-prefix) | ||
| 665 | (t t)) | ||
| 663 | (+ arg ?0))) | 666 | (+ arg ?0))) |
| 664 | (if cua--register nil arg)) | 667 | (if cua--register nil arg)) |
| 665 | 668 | ||
| 666 | |||
| 667 | ;;; Enhanced undo - restore rectangle selections | 669 | ;;; Enhanced undo - restore rectangle selections |
| 668 | 670 | ||
| 669 | (defun cua-undo (&optional arg) | 671 | (defun cua-undo (&optional arg) |