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

Unified Diff: chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc

Issue 12381035: Move Mime type handling to streamsPrivate API, so that it works on Desktop Chrome. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix base files Created 7 years, 10 months 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/renderer_host/chrome_resource_dispatcher_host_delegate.cc
diff --git a/chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc b/chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc
index 36516211496dd4ba58e3e2830dee2b2d7e643d44..36291339bc2915ec382de97cfe2cf69c69eac661 100644
--- a/chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc
+++ b/chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc
@@ -13,6 +13,7 @@
#include "chrome/browser/download/download_request_limiter.h"
#include "chrome/browser/download/download_resource_throttle.h"
#include "chrome/browser/download/download_util.h"
+#include "chrome/browser/extensions/api/streams_private/streams_resource_throttle.h"
#include "chrome/browser/extensions/user_script_listener.h"
#include "chrome/browser/external_protocol/external_protocol_handler.h"
#include "chrome/browser/google/google_util.h"
@@ -59,7 +60,6 @@
#endif
#if defined(OS_CHROMEOS)
-#include "chrome/browser/chromeos/extensions/file_browser_resource_throttle.h"
#include "chrome/browser/chromeos/login/merge_session_throttle.h"
// TODO(oshima): Enable this for other platforms.
#include "chrome/browser/renderer_host/offline_resource_throttle.h"
@@ -221,15 +221,13 @@ void ChromeResourceDispatcherHostDelegate::DownloadStarting(
// If it's from the web, we don't trust it, so we push the throttle on.
if (is_content_initiated) {
-#if defined(OS_CHROMEOS)
if (!must_download) {
ProfileIOData* io_data =
ProfileIOData::FromResourceContext(resource_context);
- throttles->push_back(FileBrowserResourceThrottle::Create(
+ throttles->push_back(StreamsResourceThrottle::Create(
child_id, route_id, request, io_data->is_incognito(),
io_data->GetExtensionInfoMap()));
}
-#endif // defined(OS_CHROMEOS)
throttles->push_back(new DownloadResourceThrottle(
download_request_limiter_, child_id, route_id, request_id,

Powered by Google App Engine
This is Rietveld 408576698