Use with-current-window instead of with-focus-window to take current window over...
authorPhilippe Brochard <pbrochard@common-lisp.net>
Mon, 22 Apr 2013 19:01:32 +0000 (21:01 +0200)
committerPhilippe Brochard <pbrochard@common-lisp.net>
Mon, 22 Apr 2013 19:01:32 +0000 (21:01 +0200)
src/clfswm-circulate-mode.lisp
src/clfswm-second-mode.lisp

index 7c52dda..720d456 100644 (file)
 
 
 (defmacro with-move-current-focused-window (() &body body)
-  (let ((window (gensym)))
-    `(with-focus-window (,window)
-       ,@body
-       (move-child-to ,window (if (frame-p (current-child))
-                                  (current-child)
-                                  (find-parent-frame (current-child) (find-current-root)))))))
+  `(with-current-window
+     ,@body
+     (move-child-to window (if (frame-p (current-child))
+                               (current-child)
+                               (find-parent-frame (current-child) (find-current-root))))))
 
 
 
index 50029f2..b8d4ac4 100644 (file)
@@ -42,7 +42,8 @@
                      (truncate (/ (- *sm-width* (* (xlib:max-char-width *sm-font*) len)) 2))
                      (truncate (/ (+ *sm-height* (- (xlib:font-ascent *sm-font*) (xlib:font-descent *sm-font*))) 2))
                      text))
-  (copy-pixmap-buffer *sm-window* *sm-gc*))
+  (copy-pixmap-buffer *sm-window* *sm-gc*)
+  (no-focus))