I'm the author of an extension called ThunderBirthDay, a data provider
for lightning displaying the birthdays of the Thunderbird addressbook
as events. The extension works quite well now and I'm close to suggest
it for public use at the mozilla add-on page [1]. IAlternatively, you
can get it from BabelZilla [2], where you don't need to be registered.
Before I can release a final version, I have to take care about a few
issues, which I was not able to do alone. These points can be found in
the readme file inside the XPI of the extension, too. I hope that
someone here can help me out!
1) I'm not 100% sure about the id attribute of calIItemBase objects.
At the beginning, I just used a random number between 0 and 1000. Now,
it's a random md5 hash for the base event, generated each time the
calender is refreshed. Is that a good idea? As the hashes change after
the calender is refreshed, it may be not.
I think, this depends on the answer to some questions: What exactly is
it for? How long is one ID assossiated with its event? Does this
assossiation end with the termination of Thunderbird or does one event
have to have the same ID every time Thunderbird starts?
I don't have any idea how to generate a unique hash for one
addressbook card which doesn't change when details of the card is
changed. If I knew such a way, I guess it would be better to use it
instead of what I'm doing now.
Last detail: I suppose that the occurrences of a recurring item have
to have the same id as the base item. Is that right?
2) This concerns the getItem function of calICalendar. I suppose that
it should return only base items of recurring items and no
occurrences. Is that right? The next thing is that I can't test it,
because I don't know where this function is used. Everywhere, items
seem only to be queried with getItem_s_.
3) While we talk about it: getItems is my next (and last) "patient".
Do the occurrences of a recurring item have to have the same title as
the base item? I guess that normaly, they have, because views and
other users of a calender can call item.getOccurrences() which copies
the title of the base item. What if I do need the different
occurrences to have a custom title (because the title of a birthday
should display the persons age)?
So, if someone could give me answers or only hints to at least some of
these questions, I'd really appriciate it! If someone even looked at
my code to see if I'm doing things right, that' be outstanding!
Regards, Ingo
[1] https://addons.mozilla.org/de/thunderbird/addon/5337
[2] http://www.babelzilla.org/forum/index.php?showtopic=3436
I have make a correction and some additions to my original post:
Unfortunately, one does have to be logged in to BabelZilla to be able
to download extension, but you might prefer it as download source
anyway... Also, I posted the same topic at Mozillazine [3], because
someone told me that people there might be able to help me, too. I
hope you don't mind...
Last but not least: I just uploaded a new version on
addons.mozilla.org (but not BabelZilla), where I cleaned up the code
and also fixed a few things. I also updated the readme.txt with the
things I need help with, but it's basically the same as my post above.
Regards, Ingo
The extension is now open for public use and available on the public
part of addons.mozilla.org (https://addons.mozilla.org/en-US/
thunderbird/addon/5337). You can find a detailed description about
installation and usage there. Feedback is very welcome.
Regards, Ingo