Forum > Win32/64
TWin32WSSelectDirectoryDialog with UseVistaDialogs?
(1/1)
lks:
I notice that that implementation uses the older SHBrowseForFolder interface instead of the more modern IFileDialog interface used by the rest of the file/open dialogs. Any reason not to use this?
For now, I have modified the TOpenDialog interface to accept an option that eventually invokes the Vista dialog with FOS_PICKFOLDERS, and it seems to work fine, so I would think it is pretty easy to add this support in the TWin32WSelectDirectoryDialog methods since it already exists in TWin32WSOpenDialog.
BigChimp:
You could alway open an issue in the bug tracker and attach your patch as you already did much of the work.
Just make sure it will work on older systems as well (e.g. Windows 2000)...
(Personnally, if the new dialog is the one were you can actually type in your desired directory instead of having to click till you turn blue, I'd be very happy with it ;) )
guitarmang:
Sorry to reply to an older post,
but I was curious on what kind of patch that user lks used. Is there anyway these options to use the new Vista style dialogs could be used, and be used with the classic theme? Here's some code from the win32wsdialogs starting on line 755:
--- Code: ---{ TWin32WSOpenDialog }
{$ifdef UseVistaDialogs}
class procedure TWin32WSOpenDialog.SetupVistaFileDialog(ADialog: IFileDialog; const AOpenDialog: TOpenDialog);
{ non-used flags
FOS_PICKFOLDERS
FOS_FORCEFILESYSTEM
FOS_ALLNONSTORAGEITEMS
FOS_HIDEMRUPLACES
FOS_HIDEPINNEDPLACES
FOS_DONTADDTORECENT
FOS_DEFAULTNOMINIMODE
FOS_FORCEPREVIEWPANEON}
--- End code ---
Thanks, Wyatt
Bart:
Lazarus uses the new Vista dialogs if:
* Themes are enabled (for the project that is)
* Windows version >= Vista
There is a bugreport requesting the use of Vista dialogs, indepently from the value of Themes enabled.
Bart
guitarmang:
Hi,
I see that there is a patch related to this now.
Is they a way you guys could include FOS_PICKFOLDERS in the options of the TOpenDialog?
Thanks, Wyatt
Navigation
[0] Message Index