Index: chrome/browser/download/download_file_picker_chromeos.cc |
diff --git a/chrome/browser/download/download_file_picker_chromeos.cc b/chrome/browser/download/download_file_picker_chromeos.cc |
index 1ee498ad0cff027b54c8b3b6f342c8f989a887c5..354c64a4fcf9ba4ec98ce8d6d6c9600700757d96 100644 |
--- a/chrome/browser/download/download_file_picker_chromeos.cc |
+++ b/chrome/browser/download/download_file_picker_chromeos.cc |
@@ -6,16 +6,18 @@ |
#include "base/bind.h" |
#include "base/file_util.h" |
+#include "base/i18n/file_util_icu.h" |
#include "base/memory/ref_counted.h" |
#include "base/threading/sequenced_worker_pool.h" |
-#include "content/public/browser/browser_thread.h" |
-#include "content/public/browser/download_item.h" |
-#include "content/public/browser/download_manager.h" |
#include "chrome/browser/chromeos/gdata/gdata_download_observer.h" |
#include "chrome/browser/chromeos/gdata/gdata_file_system.h" |
#include "chrome/browser/chromeos/gdata/gdata_system_service.h" |
#include "chrome/browser/chromeos/gdata/gdata_util.h" |
+#include "chrome/browser/download/download_util.h" |
#include "chrome/browser/profiles/profile_manager.h" |
+#include "content/public/browser/browser_thread.h" |
+#include "content/public/browser/download_item.h" |
+#include "content/public/browser/download_manager.h" |
using content::BrowserThread; |
using content::DownloadManager; |
@@ -63,9 +65,13 @@ DownloadFilePickerChromeOS::DownloadFilePickerChromeOS( |
DownloadFilePickerChromeOS::~DownloadFilePickerChromeOS() { |
} |
-void DownloadFilePickerChromeOS::FileSelected(const FilePath& path, |
+void DownloadFilePickerChromeOS::FileSelected(const FilePath& selected_path, |
int index, |
void* params) { |
+ FilePath normalized_file_name = selected_path.BaseName(); |
+ file_util::NormalizeFileNameOnChromeOS(&normalized_file_name); |
+ FilePath path = selected_path.DirName().Append(normalized_file_name); |
+ |
RecordFileSelected(path); |
if (download_manager_) { |