| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/renderer_host/download_resource_handler.h" | 5 #include "chrome/browser/renderer_host/download_resource_handler.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| 11 #include "base/metrics/stats_counters.h" | 11 #include "base/metrics/stats_counters.h" |
| 12 #include "base/stringprintf.h" | 12 #include "base/stringprintf.h" |
| 13 #include "chrome/browser/download/download_item.h" | 13 #include "chrome/browser/download/download_item.h" |
| 14 #include "chrome/browser/download/download_file_manager.h" | 14 #include "chrome/browser/download/download_file_manager.h" |
| 15 #include "chrome/browser/history/download_create_info.h" | 15 #include "chrome/browser/history/download_create_info.h" |
| 16 #include "chrome/common/resource_response.h" | |
| 17 #include "content/browser/browser_thread.h" | 16 #include "content/browser/browser_thread.h" |
| 18 #include "content/browser/renderer_host/global_request_id.h" | 17 #include "content/browser/renderer_host/global_request_id.h" |
| 19 #include "content/browser/renderer_host/resource_dispatcher_host.h" | 18 #include "content/browser/renderer_host/resource_dispatcher_host.h" |
| 20 #include "content/browser/renderer_host/resource_dispatcher_host_request_info.h" | 19 #include "content/browser/renderer_host/resource_dispatcher_host_request_info.h" |
| 20 #include "content/common/resource_response.h" |
| 21 #include "net/base/io_buffer.h" | 21 #include "net/base/io_buffer.h" |
| 22 #include "net/http/http_response_headers.h" | 22 #include "net/http/http_response_headers.h" |
| 23 #include "net/url_request/url_request_context.h" | 23 #include "net/url_request/url_request_context.h" |
| 24 | 24 |
| 25 DownloadResourceHandler::DownloadResourceHandler( | 25 DownloadResourceHandler::DownloadResourceHandler( |
| 26 ResourceDispatcherHost* rdh, | 26 ResourceDispatcherHost* rdh, |
| 27 int render_process_host_id, | 27 int render_process_host_id, |
| 28 int render_view_id, | 28 int render_view_id, |
| 29 int request_id, | 29 int request_id, |
| 30 const GURL& url, | 30 const GURL& url, |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 251 " render_view_id_ = " "%d" | 251 " render_view_id_ = " "%d" |
| 252 " save_info_.file_path = \"%" PRFilePath "\"" | 252 " save_info_.file_path = \"%" PRFilePath "\"" |
| 253 " }", | 253 " }", |
| 254 url_.spec().c_str(), | 254 url_.spec().c_str(), |
| 255 download_id_, | 255 download_id_, |
| 256 global_id_.child_id, | 256 global_id_.child_id, |
| 257 global_id_.request_id, | 257 global_id_.request_id, |
| 258 render_view_id_, | 258 render_view_id_, |
| 259 save_info_.file_path.value().c_str()); | 259 save_info_.file_path.value().c_str()); |
| 260 } | 260 } |
| OLD | NEW |