summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2014-04-17 00:35:14 +0200
committerBastien Guerry <bzg@altern.org>2014-04-17 00:35:14 +0200
commit241764b2d11e1d3b7448e75faf0c44b494a866a2 (patch)
tree5ac0730f37831ecd27866030660582f8fbca7319
parentd1600af7b62fea0da36d9282069f22516a11ea8b (diff)
downloadorg-mode-241764b2d11e1d3b7448e75faf0c44b494a866a2.tar.gz
Revert "org-agenda.el: Fix bug when using `org-agenda-do-date-later' in filtered agendas"
This reverts commit 3559ff84b244dae2109131507804b21126e0b07c.
-rw-r--r--lisp/org-agenda.el22
1 files changed, 10 insertions, 12 deletions
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 07a54c0..7055ff0 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -7658,8 +7658,8 @@ When NO-OPERATOR is non-nil, do not add the + operator to returned tags."
(defun org-agenda-filter-hide-line (type)
"Hide lines with TYPE in the agenda buffer."
(let (ov)
- (setq ov (make-overlay (max (point-min) (point-at-bol))
- (1+ (point-at-eol))))
+ (setq ov (make-overlay (max (point-min) (1- (point-at-bol)))
+ (point-at-eol)))
(overlay-put ov 'invisible t)
(overlay-put ov 'type type)
(cond ((eq type 'tag) (push ov org-agenda-tag-filter-overlays))
@@ -9940,25 +9940,23 @@ current HH:MM time."
"Drag an agenda line forward by ARG lines.
When the optional argument `backward' is non-nil, move backward."
(interactive "p")
- (let ((inhibit-read-only t) lst)
+ (let ((inhibit-read-only t) lst line)
(if (or (not (get-text-property (point) 'txt))
(save-excursion
(dotimes (n arg)
(move-beginning-of-line (if backward 0 2))
- (forward-char 1)
(push (not (get-text-property (point) 'txt)) lst))
(delq nil lst)))
- (message "Cannot move line %s" (if backward "backward" "forward"))
- (let ((end (save-excursion (move-end-of-line 1) (point)))
- (col (current-column)) line)
+ (message "Cannot move line forward")
+ (let ((end (save-excursion (move-beginning-of-line 2) (point))))
(move-beginning-of-line 1)
(setq line (buffer-substring (point) end))
- (delete-region (point) (1+ end))
- (move-end-of-line (funcall (if backward '1- '1+) (1- arg)))
- (insert "\n" line)
- (org-move-to-column col)
+ (delete-region (point) end)
+ (move-beginning-of-line (funcall (if backward '1- '1+) arg))
+ (insert line)
(org-agenda-reapply-filters)
- (org-agenda-mark-clocking-task)))))
+ (org-agenda-mark-clocking-task)
+ (move-beginning-of-line 0)))))
(defun org-agenda-drag-line-backward (arg)
"Drag an agenda line backward by ARG lines."