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

Unified Diff: content/browser/download/base_file_mac.cc

Issue 1513413002: Enable "Hide Extension" option when "Save Link As" on the Mac Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix nits. Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/download/base_file.cc ('k') | content/browser/download/download_file.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/download/base_file_mac.cc
diff --git a/content/browser/download/base_file_mac.cc b/content/browser/download/base_file_mac.cc
index f3edf12d0948c6360d306c17571e62c97b392bbe..9a756c38f02d6da0b9c0cab417e4f6821d046ad8 100644
--- a/content/browser/download/base_file_mac.cc
+++ b/content/browser/download/base_file_mac.cc
@@ -15,6 +15,13 @@ DownloadInterruptReason BaseFile::AnnotateWithSourceInformation() {
AddQuarantineMetadataToFile(full_path_, source_url_, referrer_url_);
AddOriginMetadataToFile(full_path_, source_url_, referrer_url_);
+
+ // Hide the downloaded file's extension in the Finder if the user chose that
+ // option in the save panel.
+ if (hide_file_extension_) {
+ SetExtensionHiddenForFile(full_path_, true);
+ }
+
return DOWNLOAD_INTERRUPT_REASON_NONE;
}
« no previous file with comments | « content/browser/download/base_file.cc ('k') | content/browser/download/download_file.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698