Move quickrun popup-specific config to core-popups + update rules

This commit is contained in:
Henrik Lissner 2017-05-13 22:42:59 +02:00
parent 5491fd552e
commit c5b1d56002
2 changed files with 6 additions and 11 deletions

View file

@ -85,7 +85,7 @@ is enabled/disabled.'")
("*Process List*" :size 10 :noselect t :autokill t :autoclose t)
("*Keys*" :size 10 :noselect t)
("^\\*ftp " :size 8 :noselect t :autokill t :noesc t)
(compilation-mode :size 15 :noselect t :noesc t :autokill t)
(compilation-mode :size 15 :noselect t)
(eww-mode :size 30)
(comint-mode :noesc t)
(tabulated-list-mode :noesc t)))
@ -393,11 +393,6 @@ the command buffer."
(doom--switch-from-popup (find-function-search-for-symbol fun 'defface file)))))
;; (after! magit
;; ;; Don't open files (from magit) within the magit popup
;; (advice-add #'magit-display-file-buffer-traditional :around #'doom*popups-save))
(after! neotree
;; Neotree has its own window/popup management built-in, which is difficult to
;; police. For example, switching perspectives will cause neotree to forget it
@ -423,6 +418,11 @@ the command buffer."
(setq twittering-pop-to-buffer-function #'pop-to-buffer))
(after! quickrun
;; don't auto-focus quickrun windows, shackle handles that
(setq quickrun-focus-p nil))
(after! xref
(defun doom*xref-follow-and-close (orig-fn &rest args)
"Jump to the xref on the current line, select its window and close the popup

View file

@ -89,16 +89,11 @@ invokes the repl. Takes the same arguements as `rtog/add-repl'."
quickrun-compile-only
quickrun-replace-region)
:init
;; Use standard linum-mode for quickrun eval windows; so we can have different
;; rules for it. Plus, hide modeline in it.
(add-hook 'quickrun--mode-hook #'linum-mode)
:config
(set! :popup "*quickrun*" :size 10 :noesc t :autokill t :autoclose t)
;; don't auto-focus quickrun windows. Shackle handles that for us.
(setq quickrun-focus-p nil)
(defun +eval*quickrun-auto-close (&rest _)
"Allows us to silently re-run quickrun from within the quickrun buffer."
(when-let (win (get-buffer-window quickrun--buffer-name))