From: Chong Yidong Date: Tue, 26 Apr 2011 18:31:04 +0000 (-0400) Subject: * src/nsfns.m (Fns_read_file_name): Doc fix (Bug#8534). X-Git-Tag: emacs-pretest-24.0.90~104^3~63 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=45cb8994a3e04cfa1ff50f4087998934722ee555;p=emacs.git * src/nsfns.m (Fns_read_file_name): Doc fix (Bug#8534). --- diff --git a/src/ChangeLog b/src/ChangeLog index faf9564a835..b6f962f4523 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-04-26 Chong Yidong + + * nsfns.m (Fns_read_file_name): Doc fix (Bug#8534). + 2011-04-18 Eli Zaretskii * s/ms-w32.h (localtime): Redirect to sys_localtime. diff --git a/src/nsfns.m b/src/nsfns.m index 10ce80dd480..64d3bbfbcd0 100644 --- a/src/nsfns.m +++ b/src/nsfns.m @@ -1422,10 +1422,11 @@ DEFUN ("ns-popup-color-panel", Fns_popup_color_panel, Sns_popup_color_panel, DEFUN ("ns-read-file-name", Fns_read_file_name, Sns_read_file_name, 1, 4, 0, doc: /* Use a graphical panel to read a file name, using prompt PROMPT. Optional arg DIR, if non-nil, supplies a default directory. -Optional arg ISLOAD, if non-nil, means read a file name for saving. +Optional arg MUSTMATCH, if non-nil, means the returned file or +directory must exist. Optional arg INIT, if non-nil, provides a default file name to use. */) - (prompt, dir, isLoad, init) - Lisp_Object prompt, dir, isLoad, init; + (prompt, dir, mustmatch, init) + Lisp_Object prompt, dir, mustmatch, init; { static id fileDelegate = nil; int ret; @@ -1450,7 +1451,7 @@ Optional arg INIT, if non-nil, provides a default file name to use. */) if ([dirS characterAtIndex: 0] == '~') dirS = [dirS stringByExpandingTildeInPath]; - panel = NILP (isLoad) ? + panel = NILP (mustmatch) ? (id)[EmacsSavePanel savePanel] : (id)[EmacsOpenPanel openPanel]; [panel setTitle: promptS]; @@ -1464,7 +1465,7 @@ Optional arg INIT, if non-nil, provides a default file name to use. */) panelOK = 0; BLOCK_INPUT; - if (NILP (isLoad)) + if (NILP (mustmatch)) { ret = [panel runModalForDirectory: dirS file: initS]; }