diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2014-12-05 12:49:53 -0500 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2014-12-05 12:49:53 -0500 |
commit | be307485f722be57985da979296fa37569c2a5a9 (patch) | |
tree | cff6ceeab51e5efc0825e5a8558bad4025ca6fdd /lisp/tooltip.el | |
parent | 887fa622851c7db45ccacedb1c88e13e27be5d26 (diff) | |
download | emacs-be307485f722be57985da979296fa37569c2a5a9.tar.gz |
* lisp: Prefer inlinable functions to macros.
* lisp/fringe.el (fringe-bitmap-p): Make it a plain function.
* lisp/tooltip.el (tooltip-region-active-p): Remove.
* lisp/net/shr.el (shr-char-breakable-p, shr-char-kinsoku-bol-p)
(shr-char-kinsoku-eol-p, shr-char-nospace-p): Use define-inline.
* lisp/url/url-future.el (url-future-done-p, url-future-completed-p)
(url-future-errored-p, url-future-cancelled-p):
* lisp/url/url-dav.el (url-dav-http-success-p): Use define-inline.
* lisp/vc/ediff-init.el (ediff-odd-p): Remove.
(ediff-background-face): Use cl-oddp instead.
(ediff-buffer-live-p): Make it a defsubst.
Diffstat (limited to 'lisp/tooltip.el')
-rw-r--r-- | lisp/tooltip.el | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/lisp/tooltip.el b/lisp/tooltip.el index 26cce418e45..973e74bef3a 100644 --- a/lisp/tooltip.el +++ b/lisp/tooltip.el @@ -284,10 +284,6 @@ is based on the current syntax table." (when (> (point) start) (buffer-substring start (point))))))) -(defmacro tooltip-region-active-p () - "Value is non-nil if the region should override command actions." - `(use-region-p)) - (defun tooltip-expr-to-print (event) "Return an expression that should be printed for EVENT. If a region is active and the mouse is inside the region, print @@ -295,7 +291,7 @@ the region. Otherwise, figure out the identifier around the point where the mouse is." (with-current-buffer (tooltip-event-buffer event) (let ((point (posn-point (event-end event)))) - (if (tooltip-region-active-p) + (if (use-region-p) (when (and (<= (region-beginning) point) (<= point (region-end))) (buffer-substring (region-beginning) (region-end))) (tooltip-identifier-from-point point))))) |