[Eclipse-cvs] CVS update: eclipse/input.lisp eclipse/move-resize.lisp

Iban Hatchondo ihatchondo at common-lisp.net
Mon Nov 24 13:44:50 UTC 2003


Update of /project/eclipse/cvsroot/eclipse
In directory common-lisp.net:/tmp/cvs-serv3695

Modified Files:
	input.lisp move-resize.lisp 
Log Message:
more hacking.

Date: Mon Nov 24 08:44:50 2003
Author: ihatchondo

Index: eclipse/input.lisp
diff -u eclipse/input.lisp:1.22 eclipse/input.lisp:1.23
--- eclipse/input.lisp:1.22	Mon Nov 24 08:12:01 2003
+++ eclipse/input.lisp	Mon Nov 24 08:44:50 2003
@@ -1,5 +1,5 @@
 ;;; -*- Mode: Lisp; Package: ECLIPSE-INTERNALS -*-
-;;; $Id: input.lisp,v 1.22 2003/11/24 13:12:01 ihatchondo Exp $
+;;; $Id: input.lisp,v 1.23 2003/11/24 13:44:50 ihatchondo Exp $
 ;;;
 ;;; ECLIPSE. The Common Lisp Window Manager.
 ;;; Copyright (C) 2000, 2001, 2002 Iban HATCHONDO
@@ -373,23 +373,19 @@
 	(:_NET_WM_DESKTOP
 	 (let* ((cur-desk (window-desktop-num window))
 		(new-desk (aref data 0))
-		(master-window (and master (widget-window master))))
+		(master-window (and master (widget-window master)))
+		(unmap-p (/= new-desk +any-desktop+ (current-desk))))
 	   (unless (= cur-desk new-desk)
 	     (when (shaded-p application) (shade application))
 	     (setf (window-desktop-num window) new-desk)
-	     (if (/= new-desk +any-desktop+ (current-desk))
-		 (progn
-		   (with-event-mask (*root-window*)
-		     (xlib:unmap-window (or master-window window))
-		     (when master 
-		       (with-event-mask (master-window)
-			 (xlib:unmap-window window))))
-		   (xlib:set-input-focus *display* :pointer-root :pointer-root))
-		 (if master 
-		     (with-event-mask (master-window)
-		       (xlib:map-window window)
-		       (xlib:map-window master-window))
-		     (xlib:map-window window))))))
+	     (let ((operation (if unmap-p #'xlib:unmap-window #'xlib:map-window)))
+	       (with-event-mask (*root-window*)
+		 (funcall operation (or master-window window))
+		 (when master-window
+		   (with-event-mask (master-window)
+		     (funcall operation window)))))
+	     (when unmap-p
+	       (xlib:set-input-focus *display* :pointer-root :pointer-root)))))
 	(:_NET_CLOSE_WINDOW (close-widget application))
 	(:_NET_ACTIVE_WINDOW
 	 (cond ((shaded-p application) (shade application))


Index: eclipse/move-resize.lisp
diff -u eclipse/move-resize.lisp:1.9 eclipse/move-resize.lisp:1.10
--- eclipse/move-resize.lisp:1.9	Wed Nov 19 05:29:08 2003
+++ eclipse/move-resize.lisp	Mon Nov 24 08:44:50 2003
@@ -1,5 +1,5 @@
 ;;; -*- Mode: Lisp; Package: ECLIPSE-INTERNALS -*-
-;;; $Id: move-resize.lisp,v 1.9 2003/11/19 10:29:08 ihatchondo Exp $
+;;; $Id: move-resize.lisp,v 1.10 2003/11/24 13:44:50 ihatchondo Exp $
 ;;;
 ;;; ECLIPSE. The Common Lisp Window Manager.
 ;;; Copyright (C) 2000, 2001, 2002 Iban HATCHONDO
@@ -294,8 +294,7 @@
   (declare (optimize (speed 3) (safety 0)))
   (declare (type (signed-byte 16) x y x2 y2))
   (declare (type (unsigned-byte 16) w h w2 h2))
-  (or (and (<= x (+ x2 w2)) (<= x2 (+ x w)) (<= y (+ y2 h2)) (<= y2 (+ y h)))
-      (and (<= x2 (+ x w)) (<= x (+ x2 w2)) (<= y2 (+ y h)) (<= y (+ y2 h2)))))
+  (and (<= x (+ x2 w2)) (<= x2 (+ x w)) (<= y (+ y2 h2)) (<= y2 (+ y h))))
 
 (defun region-intersect-window-in-screen (x y w h &rest windows-to-skip)
   "Returns a window list that has an intersection with the given region





More information about the Eclipse-cvs mailing list