emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: filenotify.el


From: Eli Zaretskii
Subject: Re: filenotify.el
Date: Tue, 25 Jun 2013 22:20:50 +0300

> From: Michael Albinus <address@hidden>
> Date: Tue, 25 Jun 2013 21:00:43 +0200
> Cc: address@hidden
> 
> > +     ;; Apply callback.
> > +     (when (and (stringp file) (eq action 'moved))
> > +       (funcall callback (list descriptor 'deleted file))
> > +       (setq action 'created file file1))
> > +     (when (and (stringp file) action)
> > +       (funcall callback (list descriptor action file)))))
> >
> > I don't think this is very useful because there is no way for the user to 
> > connect both events.  Inotify provides COOKIE to do this.
> >
> > Maybe we should introduce a moved-from/moved-to event using a cookie 
> > instead.  
> > This should be easier to implement for all APIs.
> 
> That's also my intention. But Glib's implementation does not implement
> this for all backends, see the comment in
> <https://developer.gnome.org/gio/2.36/GFile.html#GFileMonitorFlags-enum>.
> 
> The w32notify case I couldn't test yet.

w32notify produces 2 events for a file that was renamed: a
'renamed-from' event, followed by a 'renamed-to' event.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]