[clfswm-cvs] r8 - clfswm

pbrochard at common-lisp.net pbrochard at common-lisp.net
Sat Mar 1 21:48:33 UTC 2008


Author: pbrochard
Date: Sat Mar  1 16:48:32 2008
New Revision: 8

Modified:
   clfswm/bindings-second-mode.lisp
   clfswm/bindings.lisp
   clfswm/clfswm-internal.lisp
Log:
navigation keys change to always select the current child

Modified: clfswm/bindings-second-mode.lisp
==============================================================================
--- clfswm/bindings-second-mode.lisp	(original)
+++ clfswm/bindings-second-mode.lisp	Sat Mar  1 16:48:32 2008
@@ -1,7 +1,7 @@
 ;;; --------------------------------------------------------------------------
 ;;; CLFSWM - FullScreen Window Manager
 ;;;
-;;; #Date#: Thu Feb 28 21:38:00 2008
+;;; #Date#: Sat Mar  1 22:45:26 2008
 ;;;
 ;;; --------------------------------------------------------------------------
 ;;; Documentation: Bindings keys and mouse for second mode
@@ -173,8 +173,8 @@
 (define-second-key ("Down" :mod-1) 'select-next-level)
 (define-second-key ("Up" :mod-1) 'select-previous-level)
 
-(define-second-key ("Tab" :mod-1) 'select-next-child)
-(define-second-key ("Tab" :mod-1 :shift) 'select-previous-child)
+(define-second-key ("Tab" :mod-1) 'select-next-brother)
+(define-second-key ("Tab" :mod-1 :shift) 'select-previous-brother)
 
 (define-second-key ("Return" :mod-1) 'enter-group)
 (define-second-key ("Return" :mod-1 :shift) 'leave-group)

Modified: clfswm/bindings.lisp
==============================================================================
--- clfswm/bindings.lisp	(original)
+++ clfswm/bindings.lisp	Sat Mar  1 16:48:32 2008
@@ -1,7 +1,7 @@
 ;;; --------------------------------------------------------------------------
 ;;; CLFSWM - FullScreen Window Manager
 ;;;
-;;; #Date#: Sun Feb 24 21:34:48 2008
+;;; #Date#: Sat Mar  1 22:43:17 2008
 ;;;
 ;;; --------------------------------------------------------------------------
 ;;; Documentation: Bindings keys and mouse
@@ -48,8 +48,8 @@
 (define-main-key ("Down" :mod-1) 'select-next-level)
 (define-main-key ("Up" :mod-1) 'select-previous-level)
 
-(define-main-key ("Tab" :mod-1) 'select-next-child)
-(define-main-key ("Tab" :mod-1 :shift) 'select-previous-child)
+(define-main-key ("Tab" :mod-1) 'select-next-brother)
+(define-main-key ("Tab" :mod-1 :shift) 'select-previous-brother)
 
 (define-main-key ("Return" :mod-1) 'enter-group)
 (define-main-key ("Return" :mod-1 :shift) 'leave-group)

Modified: clfswm/clfswm-internal.lisp
==============================================================================
--- clfswm/clfswm-internal.lisp	(original)
+++ clfswm/clfswm-internal.lisp	Sat Mar  1 16:48:32 2008
@@ -1,7 +1,7 @@
 ;;; --------------------------------------------------------------------------
 ;;; CLFSWM - FullScreen Window Manager
 ;;;
-;;; #Date#: Sat Mar  1 00:03:14 2008
+;;; #Date#: Sat Mar  1 22:44:26 2008
 ;;;
 ;;; --------------------------------------------------------------------------
 ;;; Documentation: Main functions
@@ -369,12 +369,12 @@
 
 
 (defun set-focus-to-current-child ()
-  (no-focus) 
-  (when (group-p *current-child*)
-    (when (xlib:window-p (first (group-child *current-child*)))
-      (focus-window (first (group-child *current-child*)))))
-  (when (xlib:window-p *current-child*)
-    (focus-window *current-child*)))
+  (labels ((rec (child)
+	     (typecase child
+	       (xlib:window (focus-window child))
+	       (group (rec (first (group-child child)))))))
+    (no-focus)
+    (rec *current-child*)))
 
 
 
@@ -448,6 +448,7 @@
     (show-all-childs)))
 
 
+
 (defun select-next/previous-child (fun-rotate)
   "Select the next/previous child"
   (when (group-p *current-child*)
@@ -594,7 +595,8 @@
       (leave-group)
       (select-previous-level))
     ;;(unless (eql (window-type window) :maxsize) ;; PHIL: this is sufficient for the ROX panel
-    (pushnew window (group-child *current-child*)) ;)
+    (when (group-p *current-child*)
+      (pushnew window (group-child *current-child*))) ;)
     (unhide-window window)
     ;;(dbg (xlib:wm-name window) (xlib:get-wm-class window) (window-type window)) ;;; PHIL
     (case (window-type window)



More information about the clfswm-cvs mailing list