Mercurial > emacs
diff lisp/simple.el @ 105372:bd2966850aac
Use `called-interactively-p' instead of `interactive-p'.
author | Juanma Barranquero <lekktu@gmail.com> |
---|---|
date | Fri, 02 Oct 2009 03:48:36 +0000 |
parents | b24c3613ac28 |
children | 724dd25f06a9 |
line wrap: on
line diff
--- a/lisp/simple.el Fri Oct 02 00:02:02 2009 +0000 +++ b/lisp/simple.el Fri Oct 02 03:48:36 2009 +0000 @@ -3026,9 +3026,9 @@ visual feedback indicating the extent of the region being copied." (interactive "r") (copy-region-as-kill beg end) - ;; This use of interactive-p is correct + ;; This use of called-interactively-p is correct ;; because the code it controls just gives the user visual feedback. - (if (interactive-p) + (if (called-interactively-p 'interactive) (let ((other-end (if (= (point) beg) end beg)) (opoint (point)) ;; Inhibit quitting so we can make a quit here @@ -3992,7 +3992,7 @@ (end-of-line) (insert (if use-hard-newlines hard-newline "\n"))) (line-move arg nil nil try-vscroll)) - (if (interactive-p) + (if (called-interactively-p 'interactive) (condition-case nil (line-move arg nil nil try-vscroll) ((beginning-of-buffer end-of-buffer) (ding))) @@ -4022,7 +4022,7 @@ to use and more reliable (no dependence on goal column, etc.)." (interactive "^p\np") (or arg (setq arg 1)) - (if (interactive-p) + (if (called-interactively-p 'interactive) (condition-case nil (line-move (- arg) nil nil try-vscroll) ((beginning-of-buffer end-of-buffer) (ding))) @@ -6429,7 +6429,7 @@ (keyboard-translate ?\C-? ?\C-?)))) (run-hooks 'normal-erase-is-backspace-hook) - (if (interactive-p) + (if (called-interactively-p 'interactive) (message "Delete key deletes %s" (if (terminal-parameter nil 'normal-erase-is-backspace) "forward" "backward")))))