[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [h-e-w] Traditional find-file vs. file open dialog?
From: |
Bill Pringlemeir |
Subject: |
Re: [h-e-w] Traditional find-file vs. file open dialog? |
Date: |
29 Jul 2002 11:17:09 -0400 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 |
[snip]
Bill> So, I think we only have to set last-nomenu-event to nil before
Bill> calling find-file. Maybe someone with better Lisp skills can
Bill> help you. I tried "M-: (or (setq last-nomenu-event nil)
Bill> (find-file))", but that doesn't work...
Alternatively, the function "x-file-dialog" can be used to get the
file name, and then `find-file-noselect' can be called with the return
value. This is wrong, but the idea should work.
(defun find-file-gui (filename &optional wildcards)
"Attempt at GUI version."
(interactive)
(let (value (find-file-noselect (eval (x-file-dialog "" current-directory))
nil nil wildcards)))
(if (listp value)
(mapcar 'switch-to-buffer (nreverse value))
(switch-to-buffer value)))
hth,
Bill Pringlemeir.