[Kde-pim] RR: Add additional parameter to EntityTreeModel::entityData()

David Jarvie djarvie at kde.org
Mon Dec 21 17:16:44 GMT 2009


Hi Tobias,

On Mon, December 21, 2009 3:30 pm, Tobias Koenig wrote:
> On Sun, Dec 20, 2009 at 07:22:03PM +0000, David Jarvie wrote:
>> On Sunday 20 Dec 2009 13:34:32 Stephen Kelly wrote:
> Hej David,
>
>> > Can you tell me how you change the background colour of items if not by
>> > using the EntityDisplayAttribute? Is the background colour built into
>> > the alarm payload itself?
>>
>> I'm initially basing the Akonadi-based code on how I did it in
>> pre-Akonadi code, and then I'll see how it goes.
> While this is a good starting point, feel free to ask us whether some
> usecases could be done in a different way with Akonadi... During the port
> of KAddressBook I had the chance to drop a lot of old code for stuff that
> can be implemented in a much nicer way with Akonadi now.

I'm sure some things could be done better with Akonadi. There seems to be
quite a bit of work converting to Akonadi, and I'm really trying to get
there as fast as I can initially. I'm probably not taking best advantage
of what Akonadi can offer due to ignorance of Akonadi's facilities - a
good example is my wrong assumption about Attributes below.

>> The background colour in KAlarm's alarm list for each alarm is
>> user-defined per Collection
>> - it allows the user to differentiate different calendars by colour.
>> I haven't introduced any Attributes for this since it is a per-user
>> setting, so I'm intending storing it in KAlarm's config file on the
>> assumption that Attributes apply to all users.
> Akonadi is a user thingy... every user has its own Akonadi instance
> running with its own cache, so all attributes you put on your
> items/collections are on a per user basis.
> Putting as much meta information as possible into attributes removes the
> burden from you to keep track of synchronization of the config files with
> the data... yet another helpfull hand from Akonadi ;)

Thanks for that tip. It will, as you say, be easier to use attributes than
config files, now that I know they are per-user.

-- 
David Jarvie.
KDE developer.
KAlarm author - http://www.astrojar.org.uk/kalarm

_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list