summaryrefslogtreecommitdiff
path: root/lisp/textmodes/reftex.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>2007-12-25 22:44:57 +0000
committerRichard M. Stallman <rms@gnu.org>2007-12-25 22:44:57 +0000
commitf93df073e6f2b997697766f63b381c65640170b1 (patch)
tree298dd83c2be8e1778ec294e00668a3a81ad0ae7f /lisp/textmodes/reftex.el
parent22760342bfc73638d8367733ed89791747768ca9 (diff)
downloademacs-f93df073e6f2b997697766f63b381c65640170b1.tar.gz
(reftex-region-active-p): Use `use-region-p'.
Diffstat (limited to 'lisp/textmodes/reftex.el')
-rw-r--r--lisp/textmodes/reftex.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/textmodes/reftex.el b/lisp/textmodes/reftex.el
index d6ec29434d1..d7557a57d49 100644
--- a/lisp/textmodes/reftex.el
+++ b/lisp/textmodes/reftex.el
@@ -1805,11 +1805,11 @@ When DIE is non-nil, throw an error if file not found."
(buffer-substring-no-properties (match-beginning n) (match-end n))))
(defun reftex-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)
+ ;; For XEmacs.
+ (region-active-p)))
(defun reftex-kill-buffer (buffer)
;; Kill buffer if it exists.