summaryrefslogtreecommitdiff
path: root/lisp/avoid.el
diff options
context:
space:
mode:
authorKim F. Storm <storm@cua.dk>2004-08-02 15:19:24 +0000
committerKim F. Storm <storm@cua.dk>2004-08-02 15:19:24 +0000
commit5970bd01f02aee80ba8353f6f7c6e6e5512eaeb4 (patch)
treea55ddf0c3e8ba69f025a6a61320b2ac7acf59562 /lisp/avoid.el
parentec2b66c4c23c702023938f994e87fd3b01c306be (diff)
downloademacs-5970bd01f02aee80ba8353f6f7c6e6e5512eaeb4.tar.gz
(mouse-avoidance-point-position): Use window-inside-edges
and call compute-motion with nil for topos and width to get proper usable width and height for both window and non-window systems.
Diffstat (limited to 'lisp/avoid.el')
-rw-r--r--lisp/avoid.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/avoid.el b/lisp/avoid.el
index 5a5a09622cd..536b80abdbe 100644
--- a/lisp/avoid.el
+++ b/lisp/avoid.el
@@ -139,15 +139,15 @@ Only applies in mouse-avoidance-modes `animate' and `jump'."
"Return the position of point as (FRAME X . Y).
Analogous to mouse-position."
(let* ((w (selected-window))
- (edges (window-edges w))
+ (edges (window-inside-edges w))
(list
(compute-motion (max (window-start w) (point-min)) ; start pos
;; window-start can be < point-min if the
;; latter has changed since the last redisplay
'(0 . 0) ; start XY
(point) ; stop pos
- (cons (window-width) (window-height)); stop XY: none
- (1- (window-width)) ; width
+ nil ; stop XY: none
+ nil ; width
(cons (window-hscroll w) 0) ; 0 may not be right?
(selected-window))))
;; compute-motion returns (pos HPOS VPOS prevhpos contin)