Mercurial > emacs
changeset 9206:06864fef4ec3
(mouse-secondary-click-count): New variable.
(mouse-secondary-save-then-kill, mouse-drag-secondary):
Use mouse-secondary-click-count, not mouse-selection-click-count.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Sat, 01 Oct 1994 07:30:18 +0000 |
parents | 43c062993ed0 |
children | 83d8b85cd8c2 |
files | lisp/mouse.el |
diffstat | 1 files changed, 6 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/mouse.el Sat Oct 01 04:54:34 1994 +0000 +++ b/lisp/mouse.el Sat Oct 01 07:30:18 1994 +0000 @@ -636,6 +636,8 @@ ;; May be nil. (defvar mouse-secondary-overlay nil) +(defvar mouse-secondary-click-count 0) + ;; A marker which records the specified first end for a secondary selection. ;; May be nil. (defvar mouse-secondary-start nil) @@ -694,7 +696,7 @@ (click-count (1- (event-click-count start-event)))) (save-excursion (set-buffer (window-buffer start-window)) - (setq mouse-selection-click-count click-count) + (setq mouse-secondary-click-count click-count) (or mouse-secondary-overlay (setq mouse-secondary-overlay (make-overlay (point) (point)))) @@ -825,14 +827,14 @@ (error "Wrong buffer")) (save-excursion (set-buffer (window-buffer (posn-window posn))) - (if (> (mod mouse-selection-click-count 3) 0) + (if (> (mod mouse-secondary-click-count 3) 0) (if (not (and (eq last-command 'mouse-secondary-save-then-kill) (equal click-posn (car (cdr-safe (cdr-safe mouse-save-then-kill-posn)))))) ;; Find both ends of the object selected by this click. (let* ((range (mouse-start-end click-posn click-posn - mouse-selection-click-count))) + mouse-secondary-click-count))) ;; Move whichever end is closer to the click. ;; That's what xterm does, and it seems reasonable. (if (< (abs (- click-posn (overlay-start mouse-secondary-overlay))) @@ -858,7 +860,7 @@ (overlay-start mouse-secondary-overlay) (overlay-end mouse-secondary-overlay)) (setq mouse-save-then-kill-posn nil) - (setq mouse-selection-click-count 0) + (setq mouse-secondary-click-count 0) (delete-overlay mouse-secondary-overlay))) (if (and (eq last-command 'mouse-secondary-save-then-kill) mouse-save-then-kill-posn