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

Unified Diff: content/browser/download/download_item_impl.h

Issue 2809953002: Make the download's response headers available in the DownloadItem (Closed)
Patch Set: comment Created 3 years, 8 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
« no previous file with comments | « content/browser/download/download_create_info.cc ('k') | content/browser/download/download_item_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/download/download_item_impl.h
diff --git a/content/browser/download/download_item_impl.h b/content/browser/download/download_item_impl.h
index f7915d739ec5659580d99b78f2d0f9519186e60c..9b4fe748f5efa6481daf7b55a75724fcea2e8eb1 100644
--- a/content/browser/download/download_item_impl.h
+++ b/content/browser/download/download_item_impl.h
@@ -130,6 +130,8 @@ class CONTENT_EXPORT DownloadItemImpl
const GURL& GetTabUrl() const override;
const GURL& GetTabReferrerUrl() const override;
std::string GetSuggestedFilename() const override;
+ const scoped_refptr<const net::HttpResponseHeaders>& GetResponseHeaders()
+ const override;
std::string GetContentDisposition() const override;
std::string GetMimeType() const override;
std::string GetOriginalMimeType() const override;
@@ -568,7 +570,12 @@ class CONTENT_EXPORT DownloadItemImpl
// Whether the download was triggered with a user gesture.
bool has_user_gesture_ = false;
- // Information from the request.
+ // Information from the response.
+
+ // The HTTP response headers. This contains a nullptr when the response has
+ // not yet been received. Only for consuming headers.
+ scoped_refptr<const net::HttpResponseHeaders> response_headers_;
+
// Content-disposition field from the header.
std::string content_disposition_;
« no previous file with comments | « content/browser/download/download_create_info.cc ('k') | content/browser/download/download_item_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698