diff options
author | Torne (Richard Coles) <torne@google.com> | 2014-06-20 14:52:04 +0100 |
---|---|---|
committer | Torne (Richard Coles) <torne@google.com> | 2014-06-20 14:52:04 +0100 |
commit | f8ee788a64d60abd8f2d742a5fdedde054ecd910 (patch) | |
tree | 7dc14380200b953c64e0ccd16435cdbd1dbf1205 /content/browser/download | |
parent | fcbbbe23a38088a52492922075e71a419c4b01ec (diff) | |
download | chromium_org-f8ee788a64d60abd8f2d742a5fdedde054ecd910.tar.gz |
Merge from Chromium at DEPS revision 278205
This commit was generated by merge_to_master.py.
Change-Id: I23f1e7ea8c154ba72e7fb594436216f861f868ab
Diffstat (limited to 'content/browser/download')
6 files changed, 26 insertions, 24 deletions
diff --git a/content/browser/download/download_item_factory.h b/content/browser/download/download_item_factory.h index c5e03f5c41..d4198cb62e 100644 --- a/content/browser/download/download_item_factory.h +++ b/content/browser/download/download_item_factory.h @@ -44,6 +44,8 @@ public: const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, diff --git a/content/browser/download/download_item_impl.cc b/content/browser/download/download_item_impl.cc index 0fbd270da0..433ac78f48 100644 --- a/content/browser/download/download_item_impl.cc +++ b/content/browser/download/download_item_impl.cc @@ -113,6 +113,8 @@ DownloadItemImpl::DownloadItemImpl(DownloadItemImplDelegate* delegate, const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, @@ -133,6 +135,8 @@ DownloadItemImpl::DownloadItemImpl(DownloadItemImplDelegate* delegate, referrer_url_(referrer_url), transition_type_(PAGE_TRANSITION_LINK), has_user_gesture_(false), + mime_type_(mime_type), + original_mime_type_(original_mime_type), total_bytes_(total_bytes), received_bytes_(received_bytes), bytes_per_sec_(0), diff --git a/content/browser/download/download_item_impl.h b/content/browser/download/download_item_impl.h index e66026285a..34916ff6fd 100644 --- a/content/browser/download/download_item_impl.h +++ b/content/browser/download/download_item_impl.h @@ -56,6 +56,8 @@ class CONTENT_EXPORT DownloadItemImpl const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, diff --git a/content/browser/download/download_manager_impl.cc b/content/browser/download/download_manager_impl.cc index 46198075e9..2bd747d559 100644 --- a/content/browser/download/download_manager_impl.cc +++ b/content/browser/download/download_manager_impl.cc @@ -169,6 +169,8 @@ class DownloadItemFactoryImpl : public DownloadItemFactory { const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, @@ -187,6 +189,8 @@ class DownloadItemFactoryImpl : public DownloadItemFactory { target_path, url_chain, referrer_url, + mime_type, + original_mime_type, start_time, end_time, etag, @@ -619,6 +623,8 @@ DownloadItem* DownloadManagerImpl::CreateDownloadItem( const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, @@ -640,6 +646,8 @@ DownloadItem* DownloadManagerImpl::CreateDownloadItem( target_path, url_chain, referrer_url, + mime_type, + original_mime_type, start_time, end_time, etag, diff --git a/content/browser/download/download_manager_impl.h b/content/browser/download/download_manager_impl.h index 6381417832..630c83252a 100644 --- a/content/browser/download/download_manager_impl.h +++ b/content/browser/download/download_manager_impl.h @@ -7,6 +7,7 @@ #include <map> #include <set> +#include <string> #include "base/containers/hash_tables.h" #include "base/memory/ref_counted.h" @@ -78,6 +79,8 @@ class CONTENT_EXPORT DownloadManagerImpl : public DownloadManager, const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, diff --git a/content/browser/download/download_manager_impl_unittest.cc b/content/browser/download/download_manager_impl_unittest.cc index 091a7f8e6b..66430b4443 100644 --- a/content/browser/download/download_manager_impl_unittest.cc +++ b/content/browser/download/download_manager_impl_unittest.cc @@ -76,6 +76,8 @@ class MockDownloadItemImpl : public DownloadItemImpl { base::FilePath(), std::vector<GURL>(), GURL(), + "application/octet-stream", + "application/octet-stream", base::Time(), base::Time(), std::string(), @@ -234,6 +236,8 @@ class MockDownloadItemFactory const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, @@ -299,6 +303,8 @@ DownloadItemImpl* MockDownloadItemFactory::CreatePersistedItem( const base::FilePath& target_path, const std::vector<GURL>& url_chain, const GURL& referrer_url, + const std::string& mime_type, + const std::string& original_mime_type, const base::Time& start_time, const base::Time& end_time, const std::string& etag, @@ -406,34 +412,11 @@ class MockBrowserContext : public BrowserContext { MOCK_METHOD2(GetMediaRequestContextForStoragePartition, net::URLRequestContextGetter*( const base::FilePath& partition_path, bool in_memory)); - MOCK_METHOD6(RequestMidiSysExPermission, - void(int render_process_id, - int render_view_id, - int bridge_id, - const GURL& requesting_frame, - bool user_gesture, - const MidiSysExPermissionCallback& callback)); - MOCK_METHOD4(CancelMidiSysExPermissionRequest, - void(int render_process_id, - int render_view_id, - int bridge_id, - const GURL& requesting_frame)); - MOCK_METHOD4(RequestProtectedMediaIdentifierPermission, - void(int render_process_id, - int render_view_id, - const GURL& origin, - const ProtectedMediaIdentifierPermissionCallback& - callback)); - MOCK_METHOD3(CancelProtectedMediaIdentifierPermissionRequests, - void(int render_process_id, - int render_view_id, - const GURL& origin)); MOCK_METHOD0(GetResourceContext, ResourceContext*()); MOCK_METHOD0(GetDownloadManagerDelegate, DownloadManagerDelegate*()); - MOCK_METHOD0(GetGeolocationPermissionContext, - GeolocationPermissionContext* ()); MOCK_METHOD0(GetGuestManager, BrowserPluginGuestManager* ()); MOCK_METHOD0(GetSpecialStoragePolicy, quota::SpecialStoragePolicy*()); + MOCK_METHOD0(GetPushMessagingService, PushMessagingService*()); }; class MockDownloadManagerObserver : public DownloadManager::Observer { |