aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus [a t] riseup [d o t] net>2023-01-28 09:59:57 +0100
committermarty hiatt <martianhiatus [a t] riseup [d o t] net>2023-01-28 09:59:57 +0100
commit72dd0524bf5de090af3f1b1b28cd8a9be44a335e (patch)
treeff4db866201ea414b4296099b18a84fde0f0a22a
parent883a13c272092d66389df0da635869056bfb88e4 (diff)
view whole thread cmd. FIXES #378.
-rw-r--r--lisp/mastodon-tl.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el
index 9864819..04c109f 100644
--- a/lisp/mastodon-tl.el
+++ b/lisp/mastodon-tl.el
@@ -1630,6 +1630,18 @@ ID is that of the toot to view."
(let ((inhibit-read-only t))
(mastodon-tl--toot toot :detailed-p))))))
+(defun mastodon-tl--view-whole-thread ()
+ "From a thread view, view entire thread.
+If you load a thread from a toot, only the branches containing
+are displayed by default. Call this if you subsequently want to
+view all branches of a thread."
+ (interactive)
+ (if (not (eq (mastodon-tl--get-buffer-type) 'thread))
+ (error "You need to be viewing a thread to call this.")
+ (goto-char (point-min))
+ (let ((id (mastodon-tl--property 'base-toot-id)))
+ (mastodon-tl--thread id))))
+
(defun mastodon-tl--thread (&optional id)
"Open thread buffer for toot at point or with ID."
;; NB: this is called by `mastodon-url-lookup', which means it must work