فهرست منبع

Merge branch 'maint'

Nicolas Goaziou 8 سال پیش
والد
کامیت
3271cbab65
1فایلهای تغییر یافته به همراه6 افزوده شده و 9 حذف شده
  1. 6 9
      lisp/org-agenda.el

+ 6 - 9
lisp/org-agenda.el

@@ -6165,16 +6165,13 @@ specification like [h]h:mm."
 		'level level
 		'ts-date deadline
 		'priority
-		;; Adjust priority according to the associated
-		;; deadline of the item.  Past-due deadlines get
-		;; increased priority.
-		(let ((adjust (cond ((< current today) diff)
-				    ((> current today) (- repeat current))
-				    ;; Since a nil SHOW-ALL prefer
-				    ;; repeated deadlines, set
-				    ;; adjustment accordingly.
+		;; Adjust priority to today reminders about deadlines.
+		;; Overdue deadlines get the highest priority
+		;; increase, then imminent deadlines and eventually
+		;; more distant deadlines.
+		(let ((adjust (cond ((not today?) 0)
 				    ((and (not show-all) (= repeat current)) 0)
-				    (t diff))))
+				    (t (- diff)))))
 		  (+ adjust (org-get-priority item)))
 		'todo-state todo-state
 		'type (if upcoming? "upcoming-deadline" "deadline")