[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/ivy-posframe 9b084b7 174/195: Fix Minibuffer hiding doe
From: |
Feng Shu |
Subject: |
[elpa] externals/ivy-posframe 9b084b7 174/195: Fix Minibuffer hiding does not work #62 |
Date: |
Sat, 3 Oct 2020 07:12:08 -0400 (EDT) |
branch: externals/ivy-posframe
commit 9b084b7ae086a17a76a819e0ab3fad48bf5aeddb
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>
Fix Minibuffer hiding does not work #62
---
ivy-posframe.el | 20 +++++++++++---------
1 file changed, 11 insertions(+), 9 deletions(-)
diff --git a/ivy-posframe.el b/ivy-posframe.el
index 9268e3c..0cb7162 100644
--- a/ivy-posframe.el
+++ b/ivy-posframe.el
@@ -249,9 +249,6 @@ When 0, no border is showed."
"When non-nil, ivy-posframe will ignore prompt.
This variable is useful for `ivy-posframe-read-action' .")
-(defvar ivy-posframe--display-p nil
- "The status of `ivy-posframe--display'.")
-
;; Fix warn
(defvar emacs-basic-display)
@@ -259,7 +256,6 @@ This variable is useful for `ivy-posframe-read-action' .")
"Show STR in ivy's posframe with POSHANDLER."
(if (not (posframe-workable-p))
(ivy-display-function-fallback str)
- (setq ivy-posframe--display-p t)
(with-ivy-window
(apply #'posframe-show
ivy-posframe-buffer
@@ -314,8 +310,15 @@ This variable is useful for `ivy-posframe-read-action' .")
(defun ivy-posframe-cleanup ()
"Cleanup ivy's posframe."
(when (posframe-workable-p)
- (posframe-hide ivy-posframe-buffer)
- (setq ivy-posframe--display-p nil)))
+ (posframe-hide ivy-posframe-buffer))
+ ;; The below cleanup is required or not? need more test!
+ (when (and ivy-posframe-hide-minibuffer nil)
+ (with-current-buffer (window-buffer (active-minibuffer-window))
+ (let ((overlays (overlays-at (point-min))))
+ (dolist (overlay overlays)
+ (when (and (overlayp overlay)
+ (overlay-get overlay 'ivy-posframe))
+ (delete-overlay overlay)))))))
(defun ivy-posframe-dispatching-done ()
"Select one of the available actions and call `ivy-done'."
@@ -503,11 +506,10 @@ The return value is undefined.
"Advice function of FN, `ivy--minibuffer-setup' with ARGS."
(let ((ivy-fixed-height-minibuffer nil))
(apply fn args))
- (when (and ivy-posframe-hide-minibuffer
- ;; only hide minibuffer's info when posframe is showed.
- ivy-posframe--display-p)
+ (when ivy-posframe-hide-minibuffer
(let ((ov (make-overlay (point-min) (point-max) nil nil t)))
(overlay-put ov 'window (selected-window))
+ (overlay-put ov 'ivy-posframe t)
(overlay-put ov 'face
(let ((bg-color (face-background 'default nil)))
`(:background ,bg-color :foreground ,bg-color)))
- [elpa] externals/ivy-posframe 3df0c29 168/195: Merge pull request #56 from conao3/create-defun-advice, (continued)
- [elpa] externals/ivy-posframe 3df0c29 168/195: Merge pull request #56 from conao3/create-defun-advice, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe f264470 164/195: use ivy-posframe--defun-advice instead of defun, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe a489cd8 131/195: use varid function name, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe cc64ed6 115/195: extend display-functions-alist to configure-alist, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe e500f69 188/195: try and fix issues with posframe, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe d539ac2 195/195: version 0.2.0, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 76456e6 149/195: Merge pull request #46 from tttuuu888/work, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe fd1e40a 113/195: change variable name, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 2cac20d 178/195: Hide minibuffer when posframe workable, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 97337e3 109/195: fix docstring, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 9b084b7 174/195: Fix Minibuffer hiding does not work #62,
Feng Shu <=
- [elpa] externals/ivy-posframe ce7505d 171/195: Merge pull request #57 from conao3/fix-warning, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe e76565a 140/195: use (ivy-posframe-mode 1), Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 9f6628d 158/195: Add ivy-posframe-size-function #50, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 2f1fdbe 169/195: use mapc instead of mapcar, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe f4e17ae 127/195: remove unneeded configure alist variable, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 057d628 182/195: Fix for prompt line duplicated issue. #71, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 716ce62 105/195: refactoring; using let-environment, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 8ad4668 180/195: Update README, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 8abcf52 163/195: define defun-advice function, Feng Shu, 2020/10/03
- [elpa] externals/ivy-posframe 0082f43 147/195: add maintainer comment of conao3 at header, Feng Shu, 2020/10/03