[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: time for a pcb release cycle?



On Wed, 2011-09-07 at 22:47 +0100, Peter Clifton wrote:
> On Wed, 2011-09-07 at 10:56 -0700, Colin D Bennett wrote:

> > How about this for a solution:
> > 
> > 1. When saving to disk, don't disconnect/reconnect the file watch,
> >    just leave it connected.  However, ignore any file modification
> >    events until the save is completed.
> >    Set a flag: ignore_changes := True
> 
> Would have worked, apart from ...

Also, the GFileMonitor works through the GLib main loop. You only get
the events delivered _after_ the code finishes what its doing and
returns to the main loop. That would be a cause of further problems.

TBH, I think the GFileMonitor API is pretty broken for this basic
use-case. It works lovely for the one which it was (probably) intended
for - watching for changes in system config files, for new files popping
up in directories etc.., but it is not something which we can
(currently) synchronise w.r.t any other file operations we are
performing ourselves.

-- 
Peter Clifton

Electrical Engineering Division,
Engineering Department,
University of Cambridge,
9, JJ Thomson Avenue,
Cambridge
CB3 0FA

Tel: +44 (0)7729 980173 - (No signal in the lab!)
Tel: +44 (0)1223 748328 - (Shared lab phone, ask for me)

Attachment: signature.asc
Description: This is a digitally signed message part


_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user