[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [emacs-wiki-discuss] Duplicate appointments with planner-appt
From: |
Jim Ottaway |
Subject: |
Re: [emacs-wiki-discuss] Duplicate appointments with planner-appt |
Date: |
Thu, 23 Jun 2005 11:59:22 +0100 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
>>>>> Jim Ottaway <address@hidden> writes:
> Hmm...those appointments really ought ot have been deleted before we
> get to that line.
> What version of Emacs are you using?
> If you are using the CVS development version, I suspect that the real
> problem is probably in planner-appt-remember-appt: the format has
> changed slightly, so they might not get deleted with
> planner-appt-clear-appts. The change was made 2005-02-23; I wonder
> what the best way of testing for this would be?
I have looked at this using emacs 22.0.50.1, where the
appt-time-msg-list format has definitely changed. The duplicate
appointment bug is reproduced there, so I suspect even more strongly
that this is the source of the problem.
I have just come up with this as some sort of a solution; does it work
for you? You would need to comment out your changes to test it.
Regards,
Jim Ottaway
--- orig/planner-appt.el
+++ mod/planner-appt.el
@@ -517,10 +517,21 @@
(defun planner-appt-clear-appts (appt-list)
"Clear appointments in APPT-LIST from the alert list."
- (while appt-list
+ ;; Handle the new format in CVS. This is a temporary fix: I can't
+ ;; think of a better way of finding out exactly which revision is
+ ;; being used. NB. it would be more efficient to put this test in
+ ;; planner-appt-remember-appt, but there may not be any appts in
+ ;; appt-time-msg-list when it is first called.
+ (when (and appt-time-msg-list
+ (= (length (car appt-time-msg-list)) 3))
+ (setq appt-list (mapcar #'(lambda (a)
+ (append a (list t)))
+ appt-list)))
+ (while appt-list
(setq appt-time-msg-list
(delete (pop appt-list) appt-time-msg-list))))
+
(defun planner-appt-remember-appt (time text list)
"Store details of an appointment with TIME and TEXT in LIST.
Return the new list."
- Re: [emacs-wiki-discuss] Re: planner-browse-position-url quick fix, (continued)
- Re: [emacs-wiki-discuss] Re: planner-browse-position-url quick fix, Jim Ottaway, 2005/06/22
- [emacs-wiki-discuss] Duplicate appointments with planner-appt (was: planner-browse-position-url quick fix), Romain Francoise, 2005/06/23
- Re: [emacs-wiki-discuss] Duplicate appointments with planner-appt, Jim Ottaway, 2005/06/23
- [emacs-wiki-discuss] Re: Duplicate appointments with planner-appt, Romain Francoise, 2005/06/23
- Re: [emacs-wiki-discuss] Re: Duplicate appointments with planner-appt, Jim Ottaway, 2005/06/23
- Re: [emacs-wiki-discuss] Re: Duplicate appointments with planner-appt, Jim Ottaway, 2005/06/23
- [emacs-wiki-discuss] Re: Duplicate appointments with planner-appt, Romain Francoise, 2005/06/23
- [emacs-wiki-discuss] trailing whitespace and such (was: Re: Duplicate appointments with planner-appt), Vadim Nasardinov, 2005/06/23
- [emacs-wiki-discuss] Re: trailing whitespace and such, Romain Francoise, 2005/06/23
- Re: [emacs-wiki-discuss] Re: Duplicate appointments with planner-appt, Jim Ottaway, 2005/06/23
- Re: [emacs-wiki-discuss] Duplicate appointments with planner-appt,
Jim Ottaway <=
- [emacs-wiki-discuss] Welcome to Planner (was Re: planner-browse-position-url quick fix), Sacha Chua, 2005/06/22
- [emacs-wiki-discuss] Re: Welcome to Planner, Romain Francoise, 2005/06/23
- [emacs-wiki-discuss] Re: Welcome to Planner, Romain Francoise, 2005/06/24
- [emacs-wiki-discuss] Re: Welcome to Planner, Romain Francoise, 2005/06/24
- [emacs-wiki-discuss] Re: planner-browse-position-url quick fix, Zak B. Elep, 2005/06/23
[emacs-wiki-discuss] Re: planner-browse-position-url quick fix, Romain Francoise, 2005/06/21