[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/transient 2d8ceff408 185/366: transient-setup: Add emer
From: |
Jonas Bernoulli |
Subject: |
[elpa] externals/transient 2d8ceff408 185/366: transient-setup: Add emergency exit |
Date: |
Tue, 25 Jan 2022 18:54:39 -0500 (EST) |
branch: externals/transient
commit 2d8ceff4084c7e24e76152846f459974fe65c121
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>
transient-setup: Add emergency exit
---
lisp/transient.el | 47 ++++++++++++++++++++++++-----------------------
1 file changed, 24 insertions(+), 23 deletions(-)
diff --git a/lisp/transient.el b/lisp/transient.el
index 10ed3d2923..8428674a04 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -1588,29 +1588,30 @@ EDIT may be non-nil."
(when (and (>= (minibuffer-depth) 1) transient--prefix)
(error "Cannot invoke %s while minibuffer is active %s"
this-command "on behalf of another prefix command"))
- (cond
- ((not name)
- ;; Switching between regular and edit mode.
- (transient--pop-keymap 'transient--transient-map)
- (transient--pop-keymap 'transient--redisplay-map)
- (setq name (oref transient--prefix command))
- (setq params (list :scope (oref transient--prefix scope))))
- ((not (or layout ; resuming parent/suspended prefix
- transient-current-command)) ; entering child prefix
- (transient--stack-zap)) ; replace suspended prefix, if any
- (edit
- ;; Returning from help to edit.
- (setq transient--editp t)))
- (transient--init-objects name layout params)
- (transient--history-init transient--prefix)
- (setq transient--predicate-map (transient--make-predicate-map))
- (setq transient--transient-map (transient--make-transient-map))
- (setq transient--redisplay-map (transient--make-redisplay-map))
- (setq transient--original-window (selected-window))
- (setq transient--original-buffer (current-buffer))
- (transient--redisplay)
- (transient--init-transient)
- (transient--suspend-which-key-mode))
+ (transient--with-emergency-exit
+ (cond
+ ((not name)
+ ;; Switching between regular and edit mode.
+ (transient--pop-keymap 'transient--transient-map)
+ (transient--pop-keymap 'transient--redisplay-map)
+ (setq name (oref transient--prefix command))
+ (setq params (list :scope (oref transient--prefix scope))))
+ ((not (or layout ; resuming parent/suspended prefix
+ transient-current-command)) ; entering child prefix
+ (transient--stack-zap)) ; replace suspended prefix, if any
+ (edit
+ ;; Returning from help to edit.
+ (setq transient--editp t)))
+ (transient--init-objects name layout params)
+ (transient--history-init transient--prefix)
+ (setq transient--predicate-map (transient--make-predicate-map))
+ (setq transient--transient-map (transient--make-transient-map))
+ (setq transient--redisplay-map (transient--make-redisplay-map))
+ (setq transient--original-window (selected-window))
+ (setq transient--original-buffer (current-buffer))
+ (transient--redisplay)
+ (transient--init-transient)
+ (transient--suspend-which-key-mode)))
(defun transient--init-objects (name layout params)
(setq transient--prefix
- [elpa] externals/transient e2fee19879 204/366: Support using variables in group and suffix specifications, (continued)
- [elpa] externals/transient e2fee19879 204/366: Support using variables in group and suffix specifications, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 9b17afb9a0 214/366: transient-infix-set: Remove outdated claim from doc-string, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient cbc078d84c 215/366: transient--with-emergency-exit: Re-signal errors directly, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient d555d26004 221/366: transient-format-description(lisp-variable): Return string, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 9a1d62699f 222/366: transient-force-fixed-pitch: Fix doc-string, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient d85eb790e8 235/366: transient-read-directory: Pass read value through file-local-name, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 48238bf580 236/366: Allow invoking arbitrary prefixes as non-suffixes, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient a3b442243b 241/366: transient-read-{, existing-}file: New functions, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient c4bf4af655 020/366: transient--show-manpage: Fix jumping to argument, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient e4ffb97a68 018/366: transient--layout-member: Match indirect key bindings, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 2d8ceff408 185/366: transient-setup: Add emergency exit,
Jonas Bernoulli <=
- [elpa] externals/transient 601ebf5547 262/366: Quote value of slots' :initform when defining classes, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient b526b9c735 281/366: transient-infix-set: Consider all incompatibility rules, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 459e28e28a 311/366: Add lisp-imenu-generic-expression entry, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 1a1ae03600 324/366: Remove transient--pre-command later, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient e90f7a165e 335/366: Add support for returning from a sub-prefix to the parent prefix, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 8b1f8dcc51 354/366: transient--minibuffer-depth: Must always be a number, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 5762bd9a06 341/366: transient-hide-during-minibuffer-read: New option, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient de5a325616 349/366: Re-align debug declarations, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 6103f168aa 347/366: transient--describe-function: Deal with anonymous infix arguments, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 4477555b17 366/366: transient--post-exit: Deal with unbound transient slot properly, Jonas Bernoulli, 2022/01/25