diff options
author | Thierry Volpiatto <thierry.volpiatto@gmail.com> | 2019-12-22 09:40:29 +0100 |
---|---|---|
committer | Thierry Volpiatto <thierry.volpiatto@gmail.com> | 2019-12-22 09:40:29 +0100 |
commit | b701c6e40cd19b7beaecdc2cfb80c0d4d73aa172 (patch) | |
tree | 24418168c1b6a8375e1433b38d99e7e492c54ef4 /helm-lib.el | |
parent | e75f900e79309ead8fcfa629d7cb246693b9b10c (diff) |
Add hooks in helm-help (#2221)
* helm-lib.el (helm-help-mode-before-hook): New.
(helm-help-mode-after-hook): New.
(helm-help-internal): Use them.
Diffstat (limited to 'helm-lib.el')
-rw-r--r-- | helm-lib.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/helm-lib.el b/helm-lib.el index 47ad0ff4..d9bd7f6c 100644 --- a/helm-lib.el +++ b/helm-lib.el @@ -540,12 +540,17 @@ e.g helm.el$ ;;; Help routines. ;; +(defvar helm-help-mode-before-hook nil + "A hook that run before helm-help starts.") +(defvar helm-help-mode-after-hook nil + "A hook that run when helm-help exits.") (defun helm-help-internal (bufname insert-content-fn) "Show long message during `helm' session in BUFNAME. INSERT-CONTENT-FN is the function that insert text to be displayed in BUFNAME." (let ((winconf (current-frame-configuration)) (hframe (selected-frame))) + (helm-log-run-hook 'helm-help-mode-before-hook) (with-selected-frame helm-initial-frame (select-frame-set-input-focus helm-initial-frame) (unwind-protect @@ -562,6 +567,7 @@ text to be displayed in BUFNAME." (buffer-disable-undo) (helm-help-event-loop)) (raise-frame hframe) + (helm-log-run-hook 'helm-help-mode-after-hook) (setq helm-suspend-update-flag nil) (set-frame-configuration winconf))))) |