Index: chrome/browser/download/chrome_download_manager_delegate.cc |
diff --git a/chrome/browser/download/chrome_download_manager_delegate.cc b/chrome/browser/download/chrome_download_manager_delegate.cc |
index 3d609fb2e733224ca63ce2239f094415f6a16373..4e4a18cb7d7c7d9c59d205280b01663341f0336a 100644 |
--- a/chrome/browser/download/chrome_download_manager_delegate.cc |
+++ b/chrome/browser/download/chrome_download_manager_delegate.cc |
@@ -465,6 +465,13 @@ void ChromeDownloadManagerDelegate::OpenDownload(DownloadItem* download) { |
NEW_FOREGROUND_TAB, |
ui::PAGE_TRANSITION_LINK, |
false); |
+ |
+ if (download->GetOriginalMimeType() == "application/x-x509-user-cert") { |
+ params = content::OpenURLParams(GURL("chrome://settings/certificates"), |
Ryan Sleevi
2015/12/08 02:38:37
There's no way to smuggle the file name or pre-war
svaldez
2015/12/08 15:43:39
We could pipe this through, though we'll end up ha
svaldez
2015/12/08 16:34:35
So attempting to pipe this through, there isn't re
Ryan Sleevi
2015/12/09 01:27:24
Fair point. Short of reworking this UI, which we c
|
+ content::Referrer(), NEW_FOREGROUND_TAB, |
+ ui::PAGE_TRANSITION_LINK, false); |
+ } |
+ |
browser->OpenURL(params); |
RecordDownloadOpenMethod(DOWNLOAD_OPEN_METHOD_DEFAULT_BROWSER); |
#else |
@@ -720,6 +727,11 @@ void ChromeDownloadManagerDelegate::OnDownloadTargetDetermined( |
target_info->is_filetype_handled_safely) |
DownloadItemModel(item).SetShouldPreferOpeningInBrowser(true); |
+#if defined(OS_LINUX) || defined(OS_CHROMEOS) |
+ if (item->GetOriginalMimeType() == "application/x-x509-user-cert") |
+ DownloadItemModel(item).SetShouldPreferOpeningInBrowser(true); |
+#endif |
+ |
if (target_info->is_dangerous_file) |
DownloadItemModel(item).SetIsDangerousFileBasedOnType(true); |
} |