KDirWatch question

Josef Weidendorfer Josef.Weidendorfer at gmx.de
Tue Dec 21 10:25:38 GMT 2004


On Monday 20 December 2004 16:11, Andras Mantia wrote:
> On Monday 20 December 2004 12:12, Josef Weidendorfer wrote:
> > A simple access should not trigger any action from KDirWatch.
> > Or do you talk about overwriting with the same data?
>
> A simple touch filename triggers the action as well as a cvs commit. I
> want to get rid from false positives somehow.

Touching a file changes the modification time of a file, and KDirWatch always 
uses the modifcation time.

For your case, you have to open the file and check the full file content. I 
would say that such an action really depends on the application, as fully 
reading can be quite a long task, and I don't think that putting such a 
functionality into KDirWatch makes much sense: Other applications perhaps 
would only read the first few bytes...

But perhaps writing a class "KFileContentWatch", layered on top of KDirWatch 
(if it is local), makes sense to put into kdelibs. Especially if there are 
already 2 users: kate & quanta.

Josef

>
> Andras




More information about the kde-core-devel mailing list