From 3dfc5cd613bccbc6027ab79ca3aa2218cbe0ab63 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Fri, 16 Aug 2013 11:44:32 +0200 Subject: [PATCH] In mouse-autoselect-window-select do autoselect when mouse pointer is on margin. * window.el (mouse-autoselect-window-select): Do autoselect when mouse pointer is on margin. --- lisp/ChangeLog | 5 +++++ lisp/window.el | 6 ++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5edb462adb5..11b465ba991 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2013-08-16 Martin Rudalics + + * window.el (mouse-autoselect-window-select): Do autoselect when + mouse pointer is on margin. + 2013-08-16 William Parsons (tiny change) * net/ange-ftp.el (ange-ftp-skip-msgs): Add 500 EPSV. (Bug#1972) diff --git a/lisp/window.el b/lisp/window.el index e58496f6265..64cf0a72110 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -6680,8 +6680,10 @@ is active. This function is run by `mouse-autoselect-window-timer'." (cond ((or (menu-or-popup-active-p) (and window - (not (consp (coordinates-in-window-p - (cdr mouse-position) window))))) + (let ((coords (coordinates-in-window-p + (cdr mouse-position) window))) + (and (not (consp coords)) + (not (memq coords '(left-margin right-margin))))))) ;; A menu / popup dialog is active or the mouse is not on the ;; text region of WINDOW: Suspend autoselection temporarily. (mouse-autoselect-window-start mouse-position nil t)) -- 2.39.2