diff lisp/prim/mouse.el @ 70:131b0175ea99 r20-0b30

Import from CVS: tag r20-0b30
author cvs
date Mon, 13 Aug 2007 09:02:59 +0200
parents e04119814345
children 54cc21c15cbb
line wrap: on
line diff
--- a/lisp/prim/mouse.el	Mon Aug 13 09:00:04 2007 +0200
+++ b/lisp/prim/mouse.el	Mon Aug 13 09:02:59 2007 +0200
@@ -19,7 +19,7 @@
 
 ;; You should have received a copy of the GNU General Public License
 ;; along with XEmacs; see the file COPYING.  If not, write to the 
-;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Free Software Foundation, 59 Temple Place - Suite 330,
 ;; Boston, MA 02111-1307, USA.
 
 ;;; Synched up with: Not synched with FSF.  Almost completely divergent.
@@ -771,17 +771,9 @@
   (cond ((eq type 'word)
 	 ;; trap the beginning and end of buffer errors
 	 (condition-case ()
-	     (progn
-	       (setq type (char-syntax (char-after (point))))
-	       (if forwardp
-		   (if (= type ?\()
-		       (goto-char (scan-sexps (point) 1))
-		     (if (= type  ?\))
-			 (forward-char 1)
-		       (default-mouse-track-end-of-word t)))
-		 (if (= type ?\))
-		     (goto-char (scan-sexps (1+ (point)) -1))
-		   (default-mouse-track-beginning-of-word t))))
+	     (if forwardp
+		 (default-mouse-track-end-of-word t)
+	       (default-mouse-track-beginning-of-word t))
 	   (error ())))
 	((eq type 'line)
 	 (if forwardp (end-of-line) (beginning-of-line)))
@@ -1036,27 +1028,13 @@
   (setq default-mouse-track-down-event (copy-event event))
   nil)
 
-(defun default-mouse-track-cleanup-extents-hook ()
-  (remove-hook 'pre-command-hook 'default-mouse-track-cleanup-extents-hook)
+(defun default-mouse-track-cleanup-hook ()
   (let ((extent default-mouse-track-extent))
     (if (consp extent) ; rectangle-p
 	(mapcar 'delete-extent extent)
       (if extent
 	  (delete-extent extent)))))
 
-(defun default-mouse-track-cleanup-hook ()
-  (if zmacs-regions
-      (funcall 'default-mouse-track-cleanup-extents-hook)
-    (let ((extent default-mouse-track-extent)
-	  (func #'(lambda (e)
-		    (and (extent-live-p e)
-			 (set-extent-face e 'primary-selection)))))
-      (add-hook 'pre-command-hook 'default-mouse-track-cleanup-extents-hook)
-      (if (consp extent)		; rectangle-p
-	  (mapcar func extent)
-	(if extent
-	    (funcall func extent))))))
-
 (defun default-mouse-track-cleanup-extent ()
   (let ((dead-func
 	 (function (lambda (x)