# HG changeset patch # User Kim F. Storm # Date 1024667465 0 # Node ID ec1df96b1c23540197846cf7c9c9456f7b2ee196 # Parent 22df095911977e1be2bfff330c5accebae0c7cd5 (cua--prefix-arg): Make register prefixes work again. Corrected error in check for C-u initiated prefix. diff -r 22df09591197 -r ec1df96b1c23 lisp/emulation/cua-base.el --- a/lisp/emulation/cua-base.el Fri Jun 21 13:50:33 2002 +0000 +++ b/lisp/emulation/cua-base.el Fri Jun 21 13:51:05 2002 +0000 @@ -653,17 +653,19 @@ (defun cua--prefix-arg (arg) (setq cua--register (and cua-enable-register-prefix - (integerp (this-command-keys)) - (cond ((eq cua-enable-register-prefix 'not-ctrl-u) - (not (= (aref (this-command-keys) 0) ?\C-u))) - ((eq cua-enable-register-prefix 'ctrl-u-only) - (= (aref (this-command-keys) 0) ?\C-u)) - (t t)) (integerp arg) (>= arg 0) (< arg 10) + (let* ((prefix (aref (this-command-keys) 0)) + (ctrl-u-prefix (and (integerp prefix) + (= prefix ?\C-u))))) + (cond + ((eq cua-enable-register-prefix 'not-ctrl-u) + (not ctrl-u-prefix)) + ((eq cua-enable-register-prefix 'ctrl-u-only) + ctrl-u-prefix) + (t t)) (+ arg ?0))) (if cua--register nil arg)) - ;;; Enhanced undo - restore rectangle selections (defun cua-undo (&optional arg)