Lubos Lunak wrote:
As much as I don't like it, I can possibly see at least some reason for time having 25 hours, but 10 seconds without 20 seconds being 10 seconds (and there is actually explicit code to ensure that)? Does somebody know why the Time class does either of these and how much would break if I fixed these two to be sane?
Reasons for that buried in the past I guess, and maybe not too useful to try to answer - for the second question, GetHour() should be easy to grep for, and operator- has at least client code in editeng/source/misc/svxacorr.cxx, sfx2/source/doc/objcont.cxx, and automation/source/server/statemnt.cxx It's unclear to me, how valuable it is to fix-up tools/time.hxx & all client code, vs. to use e.g. http://www.boost.org/doc/libs/1_47_0/doc/html/chrono.html when you need a sane implementation in new code ... At the very least, documenting your findings in tools.hxx of course would be great. HTH, -- Thorsten
Attachment:
pgp86fGDxgE9x.pgp
Description: PGP signature