[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Replacement for KDateTime
From:       John Layt <jlayt () kde ! org>
Date:       2015-08-03 20:43:27
Message-ID: CAM1DM6mFaOupNF8s13UnadOY=tDX2mO7CHRyoXrfMa2aZr1K7Q () mail ! gmail ! com
[Download RAW message or body]

On 2 August 2015 at 19:32, David Jarvie <djarvie@kde.org> wrote:
> Having a date-only attribute in KDateTime is very useful because it allows
> both date-time and date-only values to be encapsulated in a single class.
> This avoids having to be able to pass either a QDate or QDateTime or to have
> a separate flag everywhere this is used, and it allows date-time values to
> be compared to date-only values using class methods. Without this
> encapsulation, it would make a significant amount of code more cumbersome.
> KAlarm for one will certainly need the equivalent of KDateTime even if it
> has to have its own class, but given its use in kcalcore I think it should
> be available in a library. Also, do you know that date-only is NOT used
> elsewhere (apart from kcalcore and KAlarm)?

lxr tells me it is only KCalCore and KAlarm. KCalCore uses it about 16
times. If we want KCalCore used outside kdepim then I do think they
need to try and live without the isDateOnly option and find a nice way
of doing it . For KAlarm I don't see a problem with you having your
own KADateTime class to do this.

John.
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic