]> git.eshelyaron.com Git - emacs.git/commitdiff
(Buffer-menu-make-sort-button) Make sorting by mouse-2 work from a different window.
authorDaniel Pfeiffer <occitan@esperanto.org>
Mon, 18 Oct 2004 20:45:52 +0000 (20:45 +0000)
committerDaniel Pfeiffer <occitan@esperanto.org>
Mon, 18 Oct 2004 20:45:52 +0000 (20:45 +0000)
lisp/buff-menu.el

index b00721e93ec0ee4c6dc470ff6bf73c19fa758d03..da21f5336d8f2558d98e52dac3615ddb9069783d 100644 (file)
@@ -625,7 +625,9 @@ For more information, see the function `buffer-menu'."
              'mouse-face 'highlight
              'keymap (let ((map (make-sparse-keymap)))
                        (define-key map [header-line mouse-2]
-                         `(lambda () (interactive)
+                         `(lambda (e)
+                            (interactive "e")
+                            (if e (set-buffer (window-buffer (posn-window (event-end e)))))
                             (Buffer-menu-sort ,column)))
                        map)))