فهرست منبع

Dependencies: Fix bug in blocker hook

The blocker hook did block entries if an older sibling had TODO children.
Carsten Dominik 16 سال پیش
والد
کامیت
a26aa3777e
2فایلهای تغییر یافته به همراه5 افزوده شده و 3 حذف شده
  1. 3 0
      lisp/ChangeLog
  2. 2 3
      lisp/org.el

+ 3 - 0
lisp/ChangeLog

@@ -1,5 +1,8 @@
 2009-03-27  Carsten Dominik  <carsten.dominik@gmail.com>
 
+	* org.el (org-block-todo-from-children-or-siblings): Fix bug in
+	blocker code, when an older sibling has children.
+
 	* org-mac-message.el (org-mac-message-get-link): Improve getting
 	links from multiple selected messages.
 

+ 2 - 3
lisp/org.el

@@ -8910,12 +8910,11 @@ changes.  Such blocking occurs when:
 	(let* ((this-level (funcall outline-level))
 	       (current-level this-level))
 	  (while (and (not (bobp))
-		      (= current-level this-level))
+		      (>= current-level this-level))
 	    (outline-previous-heading)
 	    (setq current-level (funcall outline-level))
 	    (if (= current-level this-level)
-		;; this todo has children, check whether they are all
-		;; completed
+		;; This is a younger sibling, check if it is completed
 		(if (and (not (org-entry-is-done-p))
 			 (org-entry-is-todo-p))
 		    (throw 'dont-block nil)))))))