From 52bb5ee5df904b8b06e1783468531622e9663a22 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Mon, 25 Aug 2014 16:23:00 -0400 Subject: Decided to keep OFN_NODEREFERENCELINKS; the Mac backend does so. --- redo/dialog.go | 1 + redo/dialog_windows.c | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/redo/dialog.go b/redo/dialog.go index f6a041f..877ccf2 100644 --- a/redo/dialog.go +++ b/redo/dialog.go @@ -5,6 +5,7 @@ package ui // OpenFile opens a dialog box that asks the user to choose a file. // It returns the selected filename, or an empty string if no file was chosen. // All events stop while OpenFile is executing. (TODO move to doc.go) +// If possible on a given system, OpenFile() will not dereference links; it will return the link file itself. func OpenFile() (filename string) { return openFile() } diff --git a/redo/dialog_windows.c b/redo/dialog_windows.c index 8b942f3..7134497 100644 --- a/redo/dialog_windows.c +++ b/redo/dialog_windows.c @@ -38,7 +38,6 @@ WCHAR *openFile(void) ofn.lpstrInitialDir = NULL; // let system decide ofn.lpstrTitle = NULL; // let system decide // TODO OFN_SHAREAWARE? - // TODO remove OFN_NODEREFERENCELINKS? or does no filters ensure that anyway? ofn.Flags = OFN_ENABLEHOOK | OFN_EXPLORER | OFN_FILEMUSTEXIST | OFN_FORCESHOWHIDDEN | OFN_HIDEREADONLY | OFN_LONGNAMES | OFN_NOCHANGEDIR | OFN_NODEREFERENCELINKS | OFN_NOTESTFILECREATE | OFN_PATHMUSTEXIST; ofn.lpfnHook = openSaveFileHook; SendMessageW(msgwin, msgBeginModal, 0, 0); -- cgit v1.2.3