mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Windows: Add default extension to file name in save dialog (issue #1646)
This commit is contained in:
@@ -511,6 +511,9 @@ bool RunSaveFileDialog(const CefBrowserHostImpl::FileChooserParams& params,
|
|||||||
ofn.lpstrFilter = filter.c_str();
|
ofn.lpstrFilter = filter.c_str();
|
||||||
// Indices into |lpstrFilter| start at 1.
|
// Indices into |lpstrFilter| start at 1.
|
||||||
ofn.nFilterIndex = *filter_index + 1;
|
ofn.nFilterIndex = *filter_index + 1;
|
||||||
|
// If a filter is specified and the default file name is changed then append
|
||||||
|
// a file extension to the new name.
|
||||||
|
ofn.lpstrDefExt = L"";
|
||||||
}
|
}
|
||||||
|
|
||||||
bool success = !!GetSaveFileName(&ofn);
|
bool success = !!GetSaveFileName(&ofn);
|
||||||
|
Reference in New Issue
Block a user