Fix lookup commands not aborting on C-g/ESC #1226
When aborting a lookup handler with C-g/ESC, Doom was convinced that it had failed legitimately, so tries the next. The expected behavior is that it abort the entire lookup operation.
This commit is contained in:
parent
4055f667fb
commit
8bfa5a30fd
1 changed files with 5 additions and 2 deletions
|
@ -134,7 +134,9 @@ Otherwise, these properties are available to be set:
|
|||
nil)))
|
||||
|
||||
(defun +lookup--jump-to (prop identifier &optional other-window)
|
||||
(let ((ret (run-hook-wrapped
|
||||
(let ((ret
|
||||
(condition-case e
|
||||
(run-hook-wrapped
|
||||
(plist-get (list :definition '+lookup-definition-functions
|
||||
:references '+lookup-references-functions
|
||||
:documentation '+lookup-documentation-functions
|
||||
|
@ -143,7 +145,8 @@ Otherwise, these properties are available to be set:
|
|||
'+lookup--run-hooks
|
||||
identifier
|
||||
(point-marker)
|
||||
other-window)))
|
||||
other-window)
|
||||
(quit (user-error "Aborted %s lookup" prop)))))
|
||||
(cond ((null ret)
|
||||
(message "Could not find '%s'" identifier)
|
||||
nil)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue