From 45578916d8500cea51369d6909a188da10863f78 Mon Sep 17 00:00:00 2001 From: Philippe Brochard Date: Wed, 14 Nov 2012 21:59:02 +0100 Subject: [PATCH] Do not update current size when there is only geometry change and not head structure change --- src/clfswm-internal.lisp | 11 +++++++---- src/clfswm.lisp | 4 ++-- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/clfswm-internal.lisp b/src/clfswm-internal.lisp index 9588f8b..8653973 100644 --- a/src/clfswm-internal.lisp +++ b/src/clfswm-internal.lisp @@ -855,7 +855,9 @@ XINERAMA version 1.1 opcode: 150 (setf (root-x root) x (root-y root) y (root-w root) w - (root-h root) h)))) + (root-h root) h))) + (setf last-sizes sizes) + :update) (create-root-geometry () (reset-root-list) ;; Add frames in *root-frame* until we get the same number as screen heads @@ -882,12 +884,13 @@ XINERAMA version 1.1 opcode: 150 ;;(add-placed-frame-tmp frame 2) ;; For tests (unless (frame-child frame) (add-frame (create-frame) frame)) - (define-as-root frame x y w h))))) + (define-as-root frame x y w h))) + (setf last-sizes sizes) + nil)) (format t "Screen sizes: ~A~%" sizes) (if (= (length sizes) (length last-sizes)) (update-root-geometry) - (create-root-geometry)) - (setf last-sizes sizes))))) + (create-root-geometry)))))) diff --git a/src/clfswm.lisp b/src/clfswm.lisp index 3a31519..25ed555 100644 --- a/src/clfswm.lisp +++ b/src/clfswm.lisp @@ -154,8 +154,8 @@ (define-handler main-mode :configure-notify (window) (when (child-equal-p window *root*) (unless (null-size-window-in-frame *root-frame*) - (place-frames-from-xinerama-infos) - (finish-configuring-root) + (unless (eql (place-frames-from-xinerama-infos) :update) + (finish-configuring-root)) (show-all-children) (call-hook *root-size-change-hook*)))) -- 2.11.4.GIT