Cleanup exwm-layout on exit

* exwm-layout.el (exwm-layout--exit): Remove
`window-pixel-width-before-size-change' hook.
This commit is contained in:
Adrián Medraño Calvo 2018-03-06 00:00:00 +00:00
parent 81529c2e89
commit c00331a7e6

View file

@ -514,6 +514,8 @@ See also `exwm-layout-enlarge-window'."
(defun exwm-layout--exit () (defun exwm-layout--exit ()
"Exit the layout module." "Exit the layout module."
(remove-hook 'window-configuration-change-hook #'exwm-layout--refresh) (remove-hook 'window-configuration-change-hook #'exwm-layout--refresh)
(when (fboundp 'window-pixel-width-before-size-change)
(remove-hook 'window-size-change-functions #'exwm-layout--refresh))
(remove-hook 'minibuffer-setup-hook #'exwm-layout--on-minibuffer-setup) (remove-hook 'minibuffer-setup-hook #'exwm-layout--on-minibuffer-setup)
(when exwm-layout--timer (when exwm-layout--timer
(cancel-timer exwm-layout--timer) (cancel-timer exwm-layout--timer)