emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/transient ebbe32e14d 028/366: transient--insert-groups:


From: Jonas Bernoulli
Subject: [elpa] externals/transient ebbe32e14d 028/366: transient--insert-groups: New function
Date: Tue, 25 Jan 2022 18:54:23 -0500 (EST)

branch: externals/transient
commit ebbe32e14de4344bb36d95040b2b62f99c60f864
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>

    transient--insert-groups: New function
---
 lisp/transient.el | 25 ++++++++++++++-----------
 1 file changed, 14 insertions(+), 11 deletions(-)

diff --git a/lisp/transient.el b/lisp/transient.el
index 30a9471b06..792ef9a028 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -2185,17 +2185,7 @@ have a history of their own.")
   (setq transient--showp t)
   (let ((transient--source-buffer (current-buffer)))
     (with-temp-buffer
-      (let ((groups (cl-mapcan (lambda (group)
-                                 (let ((hide (oref group hide)))
-                                   (and (not (and (functionp hide)
-                                                  (funcall   hide)))
-                                        (list group))))
-                               transient--layout))
-            group)
-        (while (setq group (pop groups))
-          (transient--insert-group group)
-          (when groups
-            (insert ?\n))))
+      (transient--insert-groups)
       (when (or transient--helpp transient--editp)
         (transient--insert-help))
       (delete-trailing-whitespace)
@@ -2203,6 +2193,19 @@ have a history of their own.")
             (lv-use-separator t))
         (lv-message "%s" (buffer-string))))))
 
+(defun transient--insert-groups ()
+  (let ((groups (cl-mapcan (lambda (group)
+                             (let ((hide (oref group hide)))
+                               (and (not (and (functionp hide)
+                                              (funcall   hide)))
+                                    (list group))))
+                           transient--layout))
+        group)
+    (while (setq group (pop groups))
+      (transient--insert-group group)
+      (when groups
+        (insert ?\n)))))
+
 (cl-defgeneric transient--insert-group (group)
   "Format GROUP and its elements and insert the result.")
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]