Version: (using Devel) Installed from: Compiled sources Dolphin does not honour the local time zone for change time and last access time, but the UTC time is shown. That is if I create a file at 14:00 CEST it will have a change time of 12:00 as this is the UTC time. This can be very confusing when sorting files by date and looking for a file you just changed. The terminal (ls) is getting this issue correctly. I will attach a screenshot showing both dolphin and terminal for the same files. You will see that dolphin has the UTC time stamp while ls shows the local time zone time stamp.
Created attachment 24385 [details] Screenshot showing the difference in change time in dolphin and terminal
Created attachment 24449 [details] Make KFileItem return time in local zone
This is because KFileItem returns UTC time, which is propagated to dolphin, open file dialog, property page. Is there any reason for this behaviour?
@Jakub: > This is because KFileItem returns UTC time, which is propagated > to dolphin, open file dialog, property page. > Is there any reason for this behaviour? Thanks for the patch! I don't know honestly speaking, but if David does not object I'd say that this patch should be committed.
This is just a porting issue; we didn't have timezone-aware KDateTime previously. I see that time_t is defined as UTC time, so indeed those KDateTimes use UTC. One could argue that the way those datetimes are presented to the user is up to the application, but well, I can't think if any place where we wouldn't want to use the local timezone. So IMHO the patch is OK. Ah, but it doesn't cache the result of the conversion, so it might be slow. How about this patch instead?
Created attachment 24475 [details] kfileitem.cpp patch with cache - untested, except for compilation
Thanks David for the update, I'll test your patch and will commit it afterwards!
SVN commit 800210 by ppenz: respect local time zone (patch provided by David Faure) CCMAIL: faure@kde.org BUG: 160979 M +12 -5 kfileitem.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=800210
*** Bug 157534 has been marked as a duplicate of this bug. ***
*** Bug 159309 has been marked as a duplicate of this bug. ***