Merge branch 'maint'

This commit is contained in:
Bastien Guerry 2013-07-04 15:26:35 +02:00
commit a09835d844
1 changed files with 5 additions and 3 deletions

View File

@ -23196,9 +23196,10 @@ Move to the next element at the same level, when possible."
(let* ((elem (org-element-at-point))
(end (org-element-property :end elem))
(parent (org-element-property :parent elem)))
(if (and parent (= (org-element-property :contents-end parent) end))
(goto-char (org-element-property :end parent))
(goto-char end))))))
(cond ((and parent (= (org-element-property :contents-end parent) end))
(goto-char (org-element-property :end parent)))
((integer-or-marker-p end) (goto-char end))
(t (message "No element at point")))))))
(defun org-backward-element ()
"Move backward by one element.
@ -23224,6 +23225,7 @@ Move to the previous element at the same level, when possible."
(cond
;; Move to beginning of current element if point isn't
;; there already.
((null beg) (message "No element at point"))
((/= (point) beg) (goto-char beg))
(prev-elem (goto-char (org-element-property :begin prev-elem)))
((org-before-first-heading-p) (goto-char (point-min)))