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

Issue 2825010: Saving a file with a different but known file extension will allow the select... (Closed)

Created:
10 years, 6 months ago by weinjared
Modified:
9 years, 7 months ago
CC:
chromium-reviews, ben+cc_chromium.org
Visibility:
Public.

Description

Saving a file with a different but known file extension will allow the selected extension. The new extension will only be used if the mime-type exists on the system. This addresses the case where a user *does not* change the file type to "All files" but changes the file extension. BUG=7499 TEST=Right-click on link, choose "Save link as...", leave the file type as the default but change the file name to have a different extension (different mime-type as well).

Patch Set 1 #

Total comments: 1

Patch Set 2 : '' #

Total comments: 2

Patch Set 3 : Fixed the nits but I'm not sure how to wrap them with unit tests. Any ideas? #

Patch Set 4 : added unit tests and updated chrome_tests.gypi #

Total comments: 3

Patch Set 5 : function declaration is now in header file and added test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+102 lines, -33 lines) Patch
M chrome/browser/shell_dialogs.h View 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/views/shell_dialogs_win.cc View 1 2 3 1 chunk +23 lines, -33 lines 0 comments Download
A chrome/browser/views/shell_dialogs_win_unittest.cc View 4 1 chunk +72 lines, -0 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 18 (0 generated)
weinjared
Adding Peter as a reviewer. @Peter, do you think the download shelf should be used ...
10 years, 6 months ago (2010-06-21 21:09:19 UTC) #1
Peter Kasting
We would never want to confirm that the user really meant to do what he ...
10 years, 6 months ago (2010-06-21 21:38:01 UTC) #2
weinjared
10 years, 5 months ago (2010-07-05 03:18:50 UTC) #3
Peter Kasting
You rewrote the function basically in the way I suggested, which is hard to complain ...
10 years, 5 months ago (2010-07-05 03:26:30 UTC) #4
Peter Kasting
Oh yeah, you should also update the change description.
10 years, 5 months ago (2010-07-05 03:26:44 UTC) #5
weinjared
On 2010/07/05 03:26:30, Peter Kasting wrote: > You rewrote the function basically in the way ...
10 years, 5 months ago (2010-07-05 04:53:17 UTC) #6
Peter Kasting
Unit tests would be great. Could you go ahead and add one in this patch? ...
10 years, 5 months ago (2010-07-05 17:06:04 UTC) #7
babygirlgonzales
10 years, 5 months ago (2010-07-05 17:20:21 UTC) #8
weinjared
10 years, 5 months ago (2010-07-05 18:08:34 UTC) #9
Peter Kasting
To test this you could probably declare it in an accessible scope (via an extern) ...
10 years, 5 months ago (2010-07-05 19:13:25 UTC) #10
weinjared
10 years, 5 months ago (2010-07-07 01:21:37 UTC) #11
Peter Kasting
LGTM with comments http://codereview.chromium.org/2825010/diff/13002/19001 File chrome/browser/views/shell_dialogs_win.cc (right): http://codereview.chromium.org/2825010/diff/13002/19001#newcode39 chrome/browser/views/shell_dialogs_win.cc:39: std::wstring AppendExtensionIfNeeded(const std::wstring& filename, Nit: To ...
10 years, 5 months ago (2010-07-07 02:41:44 UTC) #12
weinjared
10 years, 5 months ago (2010-07-07 22:24:45 UTC) #13
Peter Kasting
Do you need someone to land this?
10 years, 5 months ago (2010-07-07 22:31:17 UTC) #14
weinjared
On 2010/07/07 22:31:17, Peter Kasting wrote: > Do you need someone to land this? Yeah. ...
10 years, 5 months ago (2010-07-07 22:59:13 UTC) #15
Peter Kasting
On 2010/07/07 22:59:13, weinjared wrote: > Yeah. Can you land this for me? Sure, but ...
10 years, 5 months ago (2010-07-07 23:07:27 UTC) #16
weinjared
On 2010/07/07 23:07:27, Peter Kasting wrote: > On 2010/07/07 22:59:13, weinjared wrote: > > Yeah. ...
10 years, 5 months ago (2010-07-07 23:11:00 UTC) #17
Peter Kasting
10 years, 5 months ago (2010-07-08 18:49:45 UTC) #18
Landed in r51870, closing.

Powered by Google App Engine
This is Rietveld 408576698