branch: elpa/fedi
commit e86f0f9d6f7ba5f1f20f1b75035bf97f53b605a4
Author: marty hiatt <martianhiatus [a t] riseup [d o t] net>
Commit: marty hiatt <martianhiatus [a t] riseup [d o t] net>

    compose-buffer: add type, use for buffer name.
---
 fedi-post.el | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/fedi-post.el b/fedi-post.el
index be33d495b6c..4da2db47b87 100644
--- a/fedi-post.el
+++ b/fedi-post.el
@@ -536,7 +536,7 @@ Added to `after-change-functions'."
 ;;; COMPOSE BUFFER FUNCTION
 
 (defun fedi-post--compose-buffer
-    (&optional edit major minor prefix capf-funs &rest fields-alist)
+    (&optional edit major minor prefix type capf-funs &rest fields-alist)
   "Create a new buffer to capture text for a new post.
 EDIT means we are editing an existing post, not composing a new one.
 MAJOR is the major mode to enable.
@@ -545,7 +545,9 @@ PREFIX is a string corresponding to the prefix of the 
library
 that contains the compose buffer's functions. It is only required
 if this differs from the minor mode.
 CAPF-FUNS is a list of functions to enable."
-  (let* ((buffer-name (if edit "*edit post*" "*new post*"))
+  (let* ((buffer-name (if edit
+                          (format "*edit %s*" type)
+                        (format "*new %s*" type)))
          (buffer-exists (get-buffer buffer-name))
          (buffer (or buffer-exists (get-buffer-create buffer-name)))
          (inhibit-read-only t)

Reply via email to