branch: externals/hyperbole
commit 00dcf534caf6a6f65c239c17aa91012cf8d959f7
Author: Mats Lidell <[email protected]>
Commit: Mats Lidell <[email protected]>
Revert "Try and avoid using `hyperb:stack-frame`"
This reverts commit f7d4494dafc116df246e1e64d438d343708008aa.
---
hibtypes.el | 6 ++----
hmouse-drv.el | 5 +----
hui-mouse.el | 19 +++++++------------
3 files changed, 10 insertions(+), 20 deletions(-)
diff --git a/hibtypes.el b/hibtypes.el
index 0e74e5af68..cf952779c3 100644
--- a/hibtypes.el
+++ b/hibtypes.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 19-Sep-91 at 20:45:31
-;; Last-Mod: 25-Jun-23 at 10:09:04 by Mats Lidell
+;; Last-Mod: 25-Jun-23 at 16:36:20 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -255,8 +255,7 @@ display options."
(cond ((and (string-match hpath:path-variable-regexp path)
(setq path (match-string 1 path))
(hpath:is-path-variable-p path))
- (setq path (if (or assist-flag
- (bound-and-true-p hkey--within-help))
+ (setq path (if (or assist-flag (hyperb:stack-frame
'(hkey-help)))
path
(hpath:choose-from-path-variable path "Display")))
(unless (or (null path) (string-blank-p path)
@@ -360,7 +359,6 @@ in all buffers."
;; Org links in Org mode are handled at the highest priority; see the last
;; section at the end of this file.
-(defvar hibtypes--within-org-link-outside-org-mode nil)
(defib org-link-outside-org-mode ()
"Follow an Org link in a non-Org mode buffer.
diff --git a/hmouse-drv.el b/hmouse-drv.el
index 1498bd3b55..d425b03348 100644
--- a/hmouse-drv.el
+++ b/hmouse-drv.el
@@ -1018,16 +1018,13 @@ predicate is found."
(setq hkey-forms (cdr hkey-forms))))
pred-value))
-(defvar hkey--within-help nil)
-
(defun hkey-help (&optional assisting)
"Display help for the Action Key command in current context.
With optional ASSISTING prefix arg non-nil, display help for the
Assist Key command. Return non-nil iff associated help
documentation is found."
(interactive "P")
- (let* ((hkey--within-help t)
- (mouse-flag (when (mouse-event-p last-command-event)
+ (let* ((mouse-flag (when (mouse-event-p last-command-event)
(or action-key-depress-position
assist-key-depress-position)))
(mouse-drag-flag (hmouse-drag-p))
(hkey-forms (if mouse-flag hmouse-alist hkey-alist))
diff --git a/hui-mouse.el b/hui-mouse.el
index 42e9523d2d..cf7aad628d 100644
--- a/hui-mouse.el
+++ b/hui-mouse.el
@@ -3,7 +3,7 @@
;; Author: Bob Weiner
;;
;; Orig-Date: 04-Feb-89
-;; Last-Mod: 25-Jun-23 at 10:10:02 by Mats Lidell
+;; Last-Mod: 25-Jun-23 at 16:36:39 by Mats Lidell
;;
;; SPDX-License-Identifier: GPL-3.0-or-later
;;
@@ -144,6 +144,8 @@ Its default value is `smart-scroll-down'. To disable it,
set it to
(defvar magit-root-section)
(defvar magit-display-buffer-function)
+(declare-function -flatten "ext:dash")
+
(declare-function imenu--make-index-alist "imenu")
(declare-function image-dired-thumbnail-display-external "image-dired")
@@ -159,7 +161,7 @@ Its default value is `smart-scroll-down'. To disable it,
set it to
(declare-function helm-pos-header-line-p "ext:helm")
(declare-function helm-resume "ext:helm")
(declare-function helm-window "ext:helm-lib")
-;;(declare-function with-helm-buffer "ext:helm-lib")
+(declare-function with-helm-buffer "ext:helm-lib")
(defvar helm-action-buffer)
(defvar helm-alive-p)
(defvar helm-buffer)
@@ -185,12 +187,6 @@ Its default value is `smart-scroll-down'. To disable it,
set it to
(declare-function unix-apropos-get-man "ext:man-apropos")
-;;; ************************************************************************
-;;; Private variables
-;;; ************************************************************************
-
-(defvar hyp--within-smart-org nil)
-
;;; ************************************************************************
;;; Hyperbole context-sensitive keys dispatch table
;;; ************************************************************************
@@ -207,7 +203,7 @@ Its default value is `smart-scroll-down'. To disable it,
set it to
;;
;; Handle any Org mode-specific contexts but give priority to Hyperbole
;; buttons prior to cycling Org headlines
- ((and (not hyp--within-smart-org)
+ ((and (not (hyperb:stack-frame '(smart-org)))
(let ((hrule:action #'actype:identity))
(smart-org)))
. ((smart-org) . (smart-org)))
@@ -1755,9 +1751,8 @@ will invoke `org-meta-return'.
Org links may be used outside of Org mode buffers. Such links are
handled by the separate implicit button type, `org-link-outside-org-mode'."
- (let ((hyp--within-smart-org t)
- start-end)
- (when (funcall hsys-org-mode-function)
+ (when (funcall hsys-org-mode-function)
+ (let (start-end)
(cond ((not hsys-org-enable-smart-keys)
(when (hsys-org-meta-return-shared-p)
(hact 'hsys-org-meta-return))