ookii-dialogs / ookii-dialogs-wpf

Awesome dialogs for Windows Desktop applications built with Microsoft .NET (WPF)
BSD 3-Clause "New" or "Revised" License
1.14k stars 85 forks source link

Suggestion: Add ClientGuid property to file dialogs #110

Open RichardD2 opened 2 years ago

RichardD2 commented 2 years ago

The IFileDialog interface already defines the SetClientGuid and ClearClientData methods.

Adding a ClientGuid property would enable an application to maintain different sets of dialog state for different scenarios, similar to the use of the WinRT pickers' SettingsIdentifier property described by Raymond Chen back in 2020:

The SettingsIdentifier property of the various file pickers lets you give names to your pickers

It should be as simple as adding a nullable Guid property to the VistaFileDialog and VistaFolderBrowserDialog classes, and calling dialog.SetClientGuid or dialog.ClientClientData in the SetDialogProperties method.