Chromium Code Reviews

Unified Diff: chrome/browser/download/save_package.cc

Issue 18699: Fix a bug when saving web pages that have a period in their title (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
« no previous file with comments | « no previous file | chrome/browser/views/shell_dialogs.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/download/save_package.cc
===================================================================
--- chrome/browser/download/save_package.cc (revision 8505)
+++ chrome/browser/download/save_package.cc (working copy)
@@ -947,10 +947,14 @@
filter[filter.size() - 2] = L'\0';
if (g_should_prompt_for_filename) {
+ // Since we take the suggested name from the web page's title, we want to
+ // ignore the file extension generated by SaveFileAsWithFilter, since it
+ // will always be ".htm".
if (!win_util::SaveFileAsWithFilter(container_hwnd,
suggest_name,
filter,
L"htm",
+ true,
&index,
&param->saved_main_file_path))
return false;
« no previous file with comments | « no previous file | chrome/browser/views/shell_dialogs.cc » ('j') | no next file with comments »

Powered by Google App Engine