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

Unified Diff: chrome/browser/download/drag_download_item_views.cc

Issue 68133020: Fix dragging supported files to tab strip. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes Created 7 years, 1 month 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
Index: chrome/browser/download/drag_download_item_views.cc
diff --git a/chrome/browser/download/drag_download_item_views.cc b/chrome/browser/download/drag_download_item_views.cc
index 7b947188bdfb02e64f12d42d16bd91aa6d6cd19b..e7e5df59c698da4f1a9cbfa8d7337faaf7809ad2 100644
--- a/chrome/browser/download/drag_download_item_views.cc
+++ b/chrome/browser/download/drag_download_item_views.cc
@@ -46,15 +46,9 @@ void DragDownloadItem(const content::DownloadItem* download,
const base::FilePath full_path = download->GetTargetFilePath();
data.SetFilename(full_path);
- std::string mime_type = download->GetMimeType();
- if (mime_type.empty())
- net::GetMimeTypeFromFile(full_path, &mime_type);
-
// Add URL so that we can load supported files when dragged to WebContents.
- if (net::IsSupportedMimeType(mime_type)) {
- data.SetURL(net::FilePathToFileURL(full_path),
- download->GetFileNameToReportUser().LossyDisplayName());
- }
+ data.SetURL(net::FilePathToFileURL(full_path),
+ download->GetFileNameToReportUser().LossyDisplayName());
#if !defined(TOOLKIT_GTK)
#if defined(USE_AURA)

Powered by Google App Engine
This is Rietveld 408576698