Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(221)

Issue 9854011: Normalize download file name on chromeos (Closed)

Created:
8 years, 9 months ago by tbarzic
Modified:
8 years, 9 months ago
CC:
chromium-reviews, rdsmith+dwatch_chromium.org
Visibility:
Public.

Description

Normalize download file name on chromeos ChromeOS file manager cannot handle non NFC encoded utf8 file names (because of file path normalization done in webkit layer), so let's ensure we normalize downloaded file names. BUG=chromium-os:26028 TEST=downloaded file with nfd encoded names and made sure they can be handled by file manager Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=129128

Patch Set 1 #

Patch Set 2 : d > c #

Patch Set 3 : forgot tu upload patchset with added comment #

Total comments: 5

Patch Set 4 : . #

Patch Set 5 : . #

Patch Set 6 : . #

Patch Set 7 : test case #

Total comments: 4

Patch Set 8 : . #

Total comments: 3

Patch Set 9 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+69 lines, -3 lines) Patch
M base/i18n/file_util_icu.h View 1 2 3 4 5 6 7 1 chunk +4 lines, -0 lines 0 comments Download
M base/i18n/file_util_icu.cc View 1 2 3 4 5 6 7 2 chunks +12 lines, -0 lines 0 comments Download
M base/i18n/file_util_icu_unittest.cc View 1 2 3 4 5 6 7 1 chunk +22 lines, -0 lines 0 comments Download
M chrome/browser/download/download_file_picker_chromeos.cc View 1 2 3 4 5 6 7 8 2 chunks +5 lines, -1 line 0 comments Download
M chrome/browser/download/save_package_file_picker_chromeos.cc View 1 2 3 4 5 6 7 8 3 chunks +5 lines, -1 line 0 comments Download
M net/base/net_util.cc View 1 2 3 4 5 6 7 1 chunk +9 lines, -0 lines 0 comments Download
M net/base/net_util_unittest.cc View 1 2 3 4 5 6 1 chunk +12 lines, -1 line 0 comments Download

Messages

Total messages: 9 (0 generated)
tbarzic
8 years, 9 months ago (2012-03-26 18:00:07 UTC) #1
asanka
https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/chrome_download_manager_delegate.cc File chrome/browser/download/chrome_download_manager_delegate.cc (right): https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/chrome_download_manager_delegate.cc#newcode436 chrome/browser/download/chrome_download_manager_delegate.cc:436: download_util::NormalizeFileNameOnChromeOS(&generated_name); why not do this in download_util::GenerateFileNameFromRequest() or better ...
8 years, 9 months ago (2012-03-26 20:01:08 UTC) #2
tbarzic
https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/download_util.h File chrome/browser/download/download_util.h (right): https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/download_util.h#newcode55 chrome/browser/download/download_util.h:55: void NormalizeFileNameOnChromeOS(FilePath* file_name); On 2012/03/26 20:01:08, asanka wrote: > ...
8 years, 9 months ago (2012-03-26 20:45:06 UTC) #3
tbarzic
https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/chrome_download_manager_delegate.cc File chrome/browser/download/chrome_download_manager_delegate.cc (right): https://chromiumcodereview.appspot.com/9854011/diff/1006/chrome/browser/download/chrome_download_manager_delegate.cc#newcode436 chrome/browser/download/chrome_download_manager_delegate.cc:436: download_util::NormalizeFileNameOnChromeOS(&generated_name); On 2012/03/26 20:01:08, asanka wrote: > why not ...
8 years, 9 months ago (2012-03-26 20:59:50 UTC) #4
jungshik at Google
LGTM !
8 years, 9 months ago (2012-03-26 21:52:46 UTC) #5
asanka
https://chromiumcodereview.appspot.com/9854011/diff/11004/base/i18n/file_util_icu.cc File base/i18n/file_util_icu.cc (right): https://chromiumcodereview.appspot.com/9854011/diff/11004/base/i18n/file_util_icu.cc#newcode203 base/i18n/file_util_icu.cc:203: void NormalizeFileNameOnChromeOS(FilePath* file_name) { Could you also toss in ...
8 years, 9 months ago (2012-03-26 22:08:35 UTC) #6
tbarzic
asanka, ptal https://chromiumcodereview.appspot.com/9854011/diff/11004/base/i18n/file_util_icu.cc File base/i18n/file_util_icu.cc (right): https://chromiumcodereview.appspot.com/9854011/diff/11004/base/i18n/file_util_icu.cc#newcode203 base/i18n/file_util_icu.cc:203: void NormalizeFileNameOnChromeOS(FilePath* file_name) { On 2012/03/26 22:08:35, ...
8 years, 9 months ago (2012-03-26 22:57:26 UTC) #7
asanka
LGTM. Thanks! https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util_icu.cc File base/i18n/file_util_icu.cc (right): https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util_icu.cc#newcode211 base/i18n/file_util_icu.cc:211: #endif Minor nit: Perhaps throw in a ...
8 years, 9 months ago (2012-03-27 01:30:34 UTC) #8
tbarzic
8 years, 9 months ago (2012-03-27 01:32:01 UTC) #9
Noted, thanks for review!

On 2012/03/27 01:30:34, asanka wrote:
> LGTM. Thanks!
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util...
> File base/i18n/file_util_icu.cc (right):
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util...
> base/i18n/file_util_icu.cc:211: #endif
> Minor nit: Perhaps throw in a NOTIMPLEMENTED() here for other platforms. But
I'm
> fine with this either way.
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util...
> File base/i18n/file_util_icu_unittest.cc (right):
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/base/i18n/file_util...
> base/i18n/file_util_icu_unittest.cc:97: TEST_F(FileUtilICUTest,
> NormalizeFileNameEncoding) {
> Thanks for adding this!
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/chrome/browser/down...
> File chrome/browser/download/download_file_picker_chromeos.cc (right):
> 
>
https://chromiumcodereview.appspot.com/9854011/diff/10011/chrome/browser/down...
> chrome/browser/download/download_file_picker_chromeos.cc:20: #include
> "content/public/browser/download_manager.h"
> Warning: These changes might conflict with
> http://codereview.chromium.org/9809011/ . You'll want to co-ordinate with
> achuith.
> 
> Also, his CL adds a save_packge_file_picker_chromeos.cc that might also need
the
> NormalizeFileNameEncoding() treatment.

Powered by Google App Engine
This is Rietveld 408576698