Use add-hook/remove-hook instead of setq/delete

This commit is contained in:
claytharrison 2025-01-06 19:28:43 +01:00
parent 10355eec33
commit 335804a494

View file

@ -336,11 +336,9 @@ buffer."
:global t :global t
;; Forms ;; Forms
(if micromamba-env-autoactivate-mode ;; already on, now switching off (if micromamba-env-autoactivate-mode ;; already on, now switching off
(add-to-list 'window-selection-change-functions (add-hook 'window-selection-change-functions
#'micromamba--switch-buffer-auto-activate) #'micromamba--switch-buffer-auto-activate)
(setq window-selection-change-functions (remove-hook 'window-selection-change-functions #'micromamba--switch-buffer-auto-activate)))
(delete #'micromamba--switch-buffer-auto-activate
window-selection-change-functions))))
(provide 'micromamba) (provide 'micromamba)
;;; micromamba.el ends here ;;; micromamba.el ends here