From 12153c2f8d6976b15bba9bd6c51e9ebf655a937d Mon Sep 17 00:00:00 2001 From: mousebot Date: Sun, 13 Mar 2022 17:34:30 +0100 Subject: autoload and binding for translate-toot-text --- lisp/mastodon.el | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lisp') diff --git a/lisp/mastodon.el b/lisp/mastodon.el index 6eddd3d..30fc2d3 100644 --- a/lisp/mastodon.el +++ b/lisp/mastodon.el @@ -88,6 +88,9 @@ (autoload 'mastoton-tl--view-filters "mastodon-tl") ;; (autoload 'mastodon-toot--bookmark-toot-toggle "mastodon-toot") +(when (require 'lingva nil :no-error) + (autoload 'mastodon-toot--translate-toot-text "mastodon-toot")) + (defgroup mastodon nil "Interface with Mastodon." :prefix "mastodon-" @@ -167,6 +170,8 @@ Use. e.g. \"%c\" for your locale's date and time format." (define-key map (kbd "K") #'mastodon-profile--view-bookmarks) (define-key map (kbd "I") #'mastodon-tl--view-filters) (define-key map (kbd "G") #'mastodon-tl--get-follow-suggestions) + (when (require 'lingva nil :no-error) + (define-key map (kbd "s") #'mastodon-toot--translate-toot-text)) map) "Keymap for `mastodon-mode'.") -- cgit v1.2.3