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

Unified Diff: content/browser/renderer_host/resource_dispatcher_host.cc

Issue 7237034: sql::MetaTable.next_download_id, DownloadManager::GetNextId() (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: sql::MetaTable.next_download_id, DownloadId, DownloadManager::GetNextId() Created 9 years, 5 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: content/browser/renderer_host/resource_dispatcher_host.cc
diff --git a/content/browser/renderer_host/resource_dispatcher_host.cc b/content/browser/renderer_host/resource_dispatcher_host.cc
index 7030b105a227676cd035ece266b5e28cde9fe4c2..4dfae15b16b8298263bd69de8f0c33e9df75afca 100644
--- a/content/browser/renderer_host/resource_dispatcher_host.cc
+++ b/content/browser/renderer_host/resource_dispatcher_host.cc
@@ -22,6 +22,7 @@
#include "chrome/browser/download/download_manager.h"
#include "chrome/browser/download/download_request_limiter.h"
#include "chrome/browser/download/download_util.h"
+#include "chrome/browser/profiles/profile_io_data.h"
#include "chrome/browser/renderer_host/download_resource_handler.h"
#include "content/browser/appcache/chrome_appcache_service.h"
#include "content/browser/cert_store.h"
@@ -703,12 +704,18 @@ void ResourceDispatcherHost::BeginDownload(
request_id_--;
+ ProfileIOData* profile_io_data = reinterpret_cast<ProfileIOData*>(
willchan no longer on Chromium 2011/07/23 09:41:07 content/ is not allowed to depend on chrome/, so y
Randy Smith (Not in Mondays) 2011/07/25 20:20:12 In the absence of commentary from jam, I'll go wit
benjhayden 2011/07/27 19:40:54 DownloadManager is moving to content/. Could a Get
benjhayden 2011/07/27 19:40:54 Even though DownloadManager is moving to content/?
willchan no longer on Chromium 2011/07/27 19:47:14 I don't see how DownloadManager moving to content/
benjhayden 2011/07/28 15:37:52 Done.
+ context.GetUserData(NULL));
+ const DownloadManager::GetNextIdThunkType& get_next_id =
+ profile_io_data->next_download_id_thunk();
+
scoped_refptr<ResourceHandler> handler(
new DownloadResourceHandler(this,
child_id,
route_id,
request_id_,
url,
+ get_next_id,
download_file_manager_.get(),
request,
prompt_for_save_location,
@@ -729,7 +736,7 @@ void ResourceDispatcherHost::BeginDownload(
request->set_method("GET");
request->set_referrer(MaybeStripReferrer(referrer).spec());
- request->set_context(context.request_context());
+ request->set_context(request_context);
request->set_load_flags(request->load_flags() |
net::LOAD_IS_DOWNLOAD);

Powered by Google App Engine
This is Rietveld 408576698