   (defun +popup*org-src-pop-to-buffer (orig-fn buffer context)
     "Hand off the src-block window to the popup system by using `display-buffer'
 instead of switch-to-buffer-*."
-    (if (and (eq org-src-window-setup 'other-window)
+    (if (and (eq org-src-window-setup 'popup-window)
              +popup-mode)
         (pop-to-buffer buffer)
       (funcall orig-fn buffer context)))
   (advice-add #'org-src-switch-to-buffer :around #'+popup*org-src-pop-to-buffer)
-  (setq org-src-window-setup 'other-window)
+  (setq org-src-window-setup 'popup-window)
 
   ;; Ensure todo, agenda, and other minor popups are delegated to the popup system.
   (defun +popup*org-pop-to-buffer (orig-fn buf &optional norecord)


;; `org'
(after! org
  ;; Org has a scorched-earth window management system I'm not fond of. i.e. it
  ;; kills all windows and monopolizes the frame. No thanks. We can do better
  ;; ourselves.

  (setq org-agenda-window-setup 'other-window
        org-agenda-restore-windows-after-quit nil)
  ;; Don't monopolize frame!
  (defun +popup*org-agenda-suppress-delete-other-windows (orig-fn &rest args)
    (cond ((not +popup-mode)
           (apply orig-fn args))
          ((eq org-agenda-window-setup 'popup-window)
           (let (org-agenda-restore-windows-after-quit)
             (cl-letf (((symbol-function 'delete-other-windows)
                        (symbol-function 'ignore)))
               (apply orig-fn args))))
          ((memq org-agenda-window-setup '(current-window other-window))
           (with-popup-rules! nil
             (cl-letf (((symbol-function 'delete-other-windows)
                        (symbol-function 'ignore)))
               (apply orig-fn args))))
          ((with-popup-rules! nil
             (apply orig-fn args)))))
  (advice-add #'org-agenda-prepare-window :around #'+popup*org-agenda-suppress-delete-other-windows))


;; `persp-mode'
