forked from mirrors/org-mode
org.el: Prevent the display of messages when cycling from with a Gnus article buffer.
* org.el (org-cycle-internal-global): Prevent the display of messages when cycling from with a Gnus article buffer.
This commit is contained in:
parent
36cc7b4983
commit
fb31480013
54
lisp/org.el
54
lisp/org.el
|
@ -6210,34 +6210,36 @@ in special contexts.
|
||||||
|
|
||||||
(defun org-cycle-internal-global ()
|
(defun org-cycle-internal-global ()
|
||||||
"Do the global cycling action."
|
"Do the global cycling action."
|
||||||
(cond
|
;; Hack to avoid display of messages for .org attachments in Gnus
|
||||||
((and (eq last-command this-command)
|
(let ((ga (string-match "\\*fontification" (buffer-name))))
|
||||||
(eq org-cycle-global-status 'overview))
|
(cond
|
||||||
;; We just created the overview - now do table of contents
|
((and (eq last-command this-command)
|
||||||
;; This can be slow in very large buffers, so indicate action
|
(eq org-cycle-global-status 'overview))
|
||||||
(run-hook-with-args 'org-pre-cycle-hook 'contents)
|
;; We just created the overview - now do table of contents
|
||||||
(message "CONTENTS...")
|
;; This can be slow in very large buffers, so indicate action
|
||||||
(org-content)
|
(run-hook-with-args 'org-pre-cycle-hook 'contents)
|
||||||
(message "CONTENTS...done")
|
(unless ga (message "CONTENTS..."))
|
||||||
(setq org-cycle-global-status 'contents)
|
(org-content)
|
||||||
(run-hook-with-args 'org-cycle-hook 'contents))
|
(unless ga (message "CONTENTS...done"))
|
||||||
|
(setq org-cycle-global-status 'contents)
|
||||||
|
(run-hook-with-args 'org-cycle-hook 'contents))
|
||||||
|
|
||||||
((and (eq last-command this-command)
|
((and (eq last-command this-command)
|
||||||
(eq org-cycle-global-status 'contents))
|
(eq org-cycle-global-status 'contents))
|
||||||
;; We just showed the table of contents - now show everything
|
;; We just showed the table of contents - now show everything
|
||||||
(run-hook-with-args 'org-pre-cycle-hook 'all)
|
(run-hook-with-args 'org-pre-cycle-hook 'all)
|
||||||
(show-all)
|
(show-all)
|
||||||
(message "SHOW ALL")
|
(unless ga (message "SHOW ALL"))
|
||||||
(setq org-cycle-global-status 'all)
|
(setq org-cycle-global-status 'all)
|
||||||
(run-hook-with-args 'org-cycle-hook 'all))
|
(run-hook-with-args 'org-cycle-hook 'all))
|
||||||
|
|
||||||
(t
|
(t
|
||||||
;; Default action: go to overview
|
;; Default action: go to overview
|
||||||
(run-hook-with-args 'org-pre-cycle-hook 'overview)
|
(run-hook-with-args 'org-pre-cycle-hook 'overview)
|
||||||
(org-overview)
|
(org-overview)
|
||||||
(message "OVERVIEW")
|
(unless ga (message "OVERVIEW"))
|
||||||
(setq org-cycle-global-status 'overview)
|
(setq org-cycle-global-status 'overview)
|
||||||
(run-hook-with-args 'org-cycle-hook 'overview))))
|
(run-hook-with-args 'org-cycle-hook 'overview)))))
|
||||||
|
|
||||||
(defun org-cycle-internal-local ()
|
(defun org-cycle-internal-local ()
|
||||||
"Do the local cycling action."
|
"Do the local cycling action."
|
||||||
|
|
Loading…
Reference in New Issue