about summary refs log tree commit diff
path: root/exwm-layout.el
diff options
context:
space:
mode:
Diffstat (limited to 'exwm-layout.el')
-rw-r--r--exwm-layout.el9
1 files changed, 4 insertions, 5 deletions
diff --git a/exwm-layout.el b/exwm-layout.el
index ba7f65cf3bab..29273a933e2d 100644
--- a/exwm-layout.el
+++ b/exwm-layout.el
@@ -407,10 +407,9 @@ selected by `other-buffer'."
 (defun exwm-layout--on-minibuffer-setup ()
   "Refresh layout when minibuffer grows."
   (unless (exwm-workspace--client-p)
-    (run-with-idle-timer 0.01 nil         ;FIXME
-                         (lambda ()
-                           (when (< 1 (window-height (minibuffer-window)))
-                             (exwm-layout--refresh))))))
+    (exwm--defer 0 (lambda ()
+                     (when (< 1 (window-height (minibuffer-window)))
+                       (exwm-layout--refresh))))))
 
 (defun exwm-layout--on-echo-area-change (&optional dirty)
   "Run when message arrives or in `echo-area-clear-hook' to refresh layout."
@@ -421,7 +420,7 @@ selected by `other-buffer'."
                     (frame-width exwm-workspace--current))))
     (if dirty
         (exwm-layout--refresh)
-      (run-with-idle-timer 0.01 nil #'exwm-layout--refresh)))) ;FIXME
+      (exwm--defer 0 #'exwm-layout--refresh))))
 
 ;;;###autoload
 (defun exwm-layout-enlarge-window (delta &optional horizontal)