forked from mirrors/org-mode
org.el: Fix bug about cycling
* lisp/org.el (org-cycle-internal-local): Handle
`org-cycle-include-plain-lists'.
Thanks to Bruce Tulloch for reporting this.
This fixes a bug introduced in commit c2aebcee
.
This commit is contained in:
parent
a0f3bbd3c2
commit
f7175e4878
14
lisp/org.el
14
lisp/org.el
|
@ -6403,11 +6403,15 @@ Use `\\[org-edit-special]' to edit table.el tables"))
|
|||
(setq eos (save-excursion (org-end-of-subtree t t)
|
||||
(when (bolp) (backward-char)) (point)))
|
||||
(setq has-children
|
||||
(save-excursion
|
||||
(let ((level (funcall outline-level)))
|
||||
(outline-next-heading)
|
||||
(and (org-at-heading-p t)
|
||||
(> (funcall outline-level) level))))))
|
||||
(or
|
||||
(save-excursion
|
||||
(let ((level (funcall outline-level)))
|
||||
(outline-next-heading)
|
||||
(and (org-at-heading-p t)
|
||||
(> (funcall outline-level) level))))
|
||||
(and (eq org-cycle-include-plain-lists 'integrate)
|
||||
(save-excursion
|
||||
(org-list-search-forward (org-item-beginning-re) eos t))))))
|
||||
;; Determine end invisible part of buffer (EOL)
|
||||
(beginning-of-line 2)
|
||||
(while (and (not (eobp)) ;This is like `next-line'.
|
||||
|
|
Loading…
Reference in a new issue