about summary refs log tree commit diff
path: root/exwm-manage.el
diff options
context:
space:
mode:
authorChris Feng <chris.w.feng@gmail.com>2015-08-10T06·23+0800
committerChris Feng <chris.w.feng@gmail.com>2015-08-10T06·23+0800
commit048994c7948528630b5c13f56dd22a9b2972e09c (patch)
tree5c5732fde3c9a09bda4995a63c05c6e60f48120f /exwm-manage.el
parent2d4104a0eceb7d043ed1cd6bdd1bda1db4f91a73 (diff)
Remove redundant code caused by the concurrency of events (continued)
Remove `exwm--with-current-id`, which was introduced to as a wrapper to
`with-current-buffer` to do extra checks. Note that in functions run as hooks,
the validation of window ID is still required as they are not synchronized with
events.
Diffstat (limited to 'exwm-manage.el')
-rw-r--r--exwm-manage.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/exwm-manage.el b/exwm-manage.el
index 6c229481d2..9d98607898 100644
--- a/exwm-manage.el
+++ b/exwm-manage.el
@@ -35,7 +35,7 @@ corresponding buffer.")
 
 (defun exwm-manage--update-geometry (id &optional force)
   "Update window geometry."
-  (exwm--with-current-id id
+  (with-current-buffer (exwm--id->buffer id)
     (unless (and exwm--geometry (not force))
       (let ((reply (xcb:+request-unchecked+reply exwm--connection
                        (make-instance 'xcb:GetGeometry :drawable id))))
@@ -137,7 +137,7 @@ corresponding buffer.")
       (exwm-input-grab-keyboard id)
       (exwm-workspace--update-switch-history)
       (setq exwm-input--focus-lock nil) ;unlocked in advance
-      (exwm--with-current-id id
+      (with-current-buffer (exwm--id->buffer id)
         (run-hooks 'exwm-manage-finish-hook))))
   (setq exwm-input--focus-lock nil))