Merge pull request #2917 from etiktin/win_dialog_set_default_ex

Set default extension for Windows file dialogs
This commit is contained in:
Cheng Zhao 2015-09-28 12:17:05 +08:00
commit c18fa63db6

View file

@ -79,6 +79,9 @@ class FileDialog {
if (!title.empty())
GetPtr()->SetTitle(base::UTF8ToUTF16(title).c_str());
if (!filterspec.empty())
GetPtr()->SetDefaultExtension(filterspec.front().pszSpec);
SetDefaultFolder(default_path);
}