Skip to content

Commit

Permalink
windows: hide read-only option from open file dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
samangh committed Mar 10, 2024
1 parent a252228 commit 309b7f2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions portable-file-dialogs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1184,6 +1184,7 @@ inline internal::file_dialog::file_dialog(type in_type,
if (in_type == type::open)
ofn.Flags |= OFN_FILEMUSTEXIST;
ofn.Flags |= OFN_PATHMUSTEXIST;
ofn.Flags |= OFN_HIDEREADONLY;

dll::proc<BOOL WINAPI (LPOPENFILENAMEW)> get_open_file_name(comdlg32, "GetOpenFileNameW");
if (get_open_file_name(&ofn) == 0)
Expand Down

0 comments on commit 309b7f2

Please sign in to comment.