summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien <bzg@gnu.org>2020-02-05 00:36:42 +0100
committerBastien <bzg@gnu.org>2020-02-05 00:36:42 +0100
commit19676dce758038749887a057208ea33d9a1fad57 (patch)
treeee0d82e172a6959d81b49c0c6f4101ad894f49fb
parentd8c51531c0716f5e73f6e517037632ea863d8c34 (diff)
downloadorg-mode-19676dce758038749887a057208ea33d9a1fad57.tar.gz
org-agenda.el: Fix `org-agenda-show-new-time'
* lisp/org-agenda.el (org-agenda-show-new-time): Fix infinite loop while trying to show new time in hidden lines. Thanks to Andrew Hyatt for reporting this.
-rw-r--r--lisp/org-agenda.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index a98bab2..aed7f86 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -9571,7 +9571,9 @@ Called with a universal prefix arg, show the priority instead of setting it."
(goto-char (point-max))
(while (not (bobp))
(when (equal marker (org-get-at-bol 'org-marker))
- (remove-text-properties (point-at-bol) (point-at-eol) '(display nil))
+ (remove-text-properties (line-beginning-position)
+ (line-end-position)
+ '(display nil))
(org-move-to-column
(- (/ (window-width nil t) (window-font-width)) (length stamp)) t)
(add-text-properties
@@ -9579,7 +9581,7 @@ Called with a universal prefix arg, show the priority instead of setting it."
(list 'display (org-add-props stamp nil
'face '(secondary-selection default))))
(beginning-of-line 1))
- (beginning-of-line 0)))))
+ (org-agenda-previous-line)))))
(defun org-agenda-date-prompt (arg)
"Change the date of this item. Date is prompted for, with default today.