Mercurial > emacs
changeset 87399:16b2c36a354d
(idlwave-region-active-p): Use `use-region-p'.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 25 Dec 2007 22:45:27 +0000 |
parents | 5aca203bab2c |
children | f5538ebc9577 |
files | lisp/progmodes/idlwave.el |
diffstat | 1 files changed, 4 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/idlwave.el Tue Dec 25 22:44:57 2007 +0000 +++ b/lisp/progmodes/idlwave.el Tue Dec 25 22:45:27 2007 +0000 @@ -2112,15 +2112,11 @@ (backward-char 1) (point))))) -(defvar transient-mark-mode) -(defvar zmacs-regions) -(defvar mark-active) (defun idlwave-region-active-p () - "Is transient-mark-mode on and the region active? -Works on both Emacs and XEmacs." - (if (featurep 'xemacs) - (and zmacs-regions (region-active-p)) - (and transient-mark-mode mark-active))) + "Should we operate on an active region?" + (if (fboundp 'use-region-p) + (use-region-p) + (region-active-p))) (defun idlwave-show-matching-quote () "Insert quote and show matching quote if this is end of a string."