X-Git-Url: https://git.hcoop.net/bpt/emacs.git/blobdiff_plain/eb3fa2cfcfff550c08f5645c740608f97c2c949e..e1ef0dac0866570df62f96fb004de896f6e82397:/lisp/mouse-copy.el diff --git a/lisp/mouse-copy.el b/lisp/mouse-copy.el index 9495ca55c2..2b3b23904c 100644 --- a/lisp/mouse-copy.el +++ b/lisp/mouse-copy.el @@ -1,7 +1,7 @@ ;;; mouse-copy.el --- one-click text copy and move ;; Copyright (C) 1996, 2001, 2002, 2003, 2004, 2005, -;; 2006, 2007, 2008 Free Software Foundation, Inc. +;; 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. ;; Author: John Heidemann ;; Keywords: mouse @@ -200,8 +200,7 @@ by johnh@ficus.cs.ucla.edu." (window-buffer (posn-window (event-start click))) (current-buffer))) (error "Select or click on the buffer where the secondary selection is"))) - (save-excursion - (set-buffer (overlay-buffer mouse-secondary-overlay)) + (with-current-buffer (overlay-buffer mouse-secondary-overlay) (kill-region (overlay-start mouse-secondary-overlay) (overlay-end mouse-secondary-overlay))) ;; (delete-overlay mouse-secondary-overlay) @@ -223,5 +222,4 @@ by johnh@ficus.cs.ucla.edu." (provide 'mouse-copy) -;; arch-tag: 3d50293b-c089-4273-b412-4fc96a5f26ff ;;; mouse-copy.el ends here