Subject: bug#12915: 24.2.50; Visiting a file via drag-and-drop should add it to the history of visited files

From: Stefan Monnier <[email-masked]>
Date: Sat, 12 Jan 2013 08:18:03 -0500

> I think it is best done by adding an optional argument `add-history' to
> `find-file' (and similar functions like `find-file-other-frame'), so
> that Lisp callers can specify to update `file-name-history' even if the
> file name was not read interactively.  Any objections?

Maybe a more automatic way is to provide a `display-buffer-hook', that's
run from `set-window-buffer', and then have find-file-noselect use this
hook to add the file name onto the history if the buffer is shown to
the user.

        Stefan