X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/ba3189039adc8ec5eba5ed3e21d42019a4616b7c..9fb185aff7b1f36c30bd157ec446d9bad104d1ee:/lisp/mouse-drag.el diff --git a/lisp/mouse-drag.el b/lisp/mouse-drag.el index a0115f8ea6..e46ea00d7e 100644 --- a/lisp/mouse-drag.el +++ b/lisp/mouse-drag.el @@ -1,6 +1,6 @@ ;;; mouse-drag.el --- use mouse-2 to do a new style of scrolling -;; Copyright (C) 1996-1997, 2001-2014 Free Software Foundation, Inc. +;; Copyright (C) 1996-1997, 2001-2016 Free Software Foundation, Inc. ;; Author: John Heidemann ;; Keywords: mouse @@ -206,7 +206,7 @@ about which direction is natural. Perhaps it has to do with which hemisphere you're in.) To test this function, evaluate: - (global-set-key [down-mouse-2] 'mouse-drag-throw)" + (global-set-key [down-mouse-2] \\='mouse-drag-throw)" (interactive "e") ;; we want to do save-selected-window, but that requires 19.29 (let* ((start-posn (event-start start-event)) @@ -222,6 +222,8 @@ To test this function, evaluate: (col-scrolling-p (mouse-drag-should-do-col-scrolling))) (select-window start-window) (track-mouse + ;; Don't change the mouse pointer shape while we drag. + (setq track-mouse 'dragging) (while (progn (setq event (read-event) end (event-end event) @@ -264,7 +266,7 @@ Drag scrolling is identical to the \"hand\" option in MacPaint, or the middle button in Tk text widgets. To test this function, evaluate: - (global-set-key [down-mouse-2] 'mouse-drag-drag)" + (global-set-key [down-mouse-2] \\='mouse-drag-drag)" (interactive "e") ;; we want to do save-selected-window, but that requires 19.29 (let* ((start-posn (event-start start-event)) @@ -291,7 +293,7 @@ To test this function, evaluate: (or (mouse-movement-p event) (eq (car-safe event) 'switch-frame))) ;; Scroll if see if we're on the edge. - ;; NEEDSWORK: should handle mouse-in-other window. + ;; FIXME: should handle mouse-in-other window. (cond ((not (eq start-window (posn-window end))) t) ; wait for return to original window