Fix persisted workspace storing broken posframes #1017
Not confident this is the best solution, but it will work for now.
This commit is contained in:
parent
ab79799407
commit
cf07bac383
1 changed files with 4 additions and 0 deletions
|
@ -205,6 +205,10 @@ immediately runs it on the current candidate (ending the ivy session)."
|
||||||
;; default to posframe display function
|
;; default to posframe display function
|
||||||
(setf (alist-get t ivy-display-functions-alist) #'+ivy-display-at-frame-center-near-bottom)
|
(setf (alist-get t ivy-display-functions-alist) #'+ivy-display-at-frame-center-near-bottom)
|
||||||
|
|
||||||
|
;; Fix #1017: stop session persistence from restoring a broken posframe
|
||||||
|
(defun +workspace|delete-all-posframes (&rest _) (posframe-delete-all))
|
||||||
|
(add-hook 'persp-after-load-state-functions #'+workspace|delete-all-posframes)
|
||||||
|
|
||||||
;; posframe doesn't work well with async sources
|
;; posframe doesn't work well with async sources
|
||||||
(dolist (fn '(swiper counsel-ag counsel-grep counsel-git-grep))
|
(dolist (fn '(swiper counsel-ag counsel-grep counsel-git-grep))
|
||||||
(setf (alist-get fn ivy-display-functions-alist) #'ivy-display-function-fallback)))
|
(setf (alist-get fn ivy-display-functions-alist) #'ivy-display-function-fallback)))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue