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

Side by Side Diff: content/browser/download/download_create_info.cc

Issue 8371009: Make passing of DownloadRequestHandle separate from DownloadCreateInfo. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to LKGR. Created 9 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "content/browser/download/download_create_info.h" 5 #include "content/browser/download/download_create_info.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/format_macros.h" 9 #include "base/format_macros.h"
10 #include "base/stringprintf.h" 10 #include "base/stringprintf.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 DownloadCreateInfo::~DownloadCreateInfo() { 47 DownloadCreateInfo::~DownloadCreateInfo() {
48 } 48 }
49 49
50 std::string DownloadCreateInfo::DebugString() const { 50 std::string DownloadCreateInfo::DebugString() const {
51 return base::StringPrintf("{" 51 return base::StringPrintf("{"
52 " download_id = %d" 52 " download_id = %d"
53 " url = \"%s\"" 53 " url = \"%s\""
54 " path = \"%" PRFilePath "\"" 54 " path = \"%" PRFilePath "\""
55 " received_bytes = %" PRId64 55 " received_bytes = %" PRId64
56 " total_bytes = %" PRId64 56 " total_bytes = %" PRId64
57 " request_handle = %s"
58 " prompt_user_for_save_location = %c" 57 " prompt_user_for_save_location = %c"
59 " }", 58 " }",
60 download_id, 59 download_id,
61 url().spec().c_str(), 60 url().spec().c_str(),
62 path.value().c_str(), 61 path.value().c_str(),
63 received_bytes, 62 received_bytes,
64 total_bytes, 63 total_bytes,
65 request_handle.DebugString().c_str(),
66 prompt_user_for_save_location ? 'T' : 'F'); 64 prompt_user_for_save_location ? 'T' : 'F');
67 } 65 }
68 66
69 const GURL& DownloadCreateInfo::url() const { 67 const GURL& DownloadCreateInfo::url() const {
70 return url_chain.empty() ? GURL::EmptyGURL() : url_chain.back(); 68 return url_chain.empty() ? GURL::EmptyGURL() : url_chain.back();
71 } 69 }
OLDNEW
« no previous file with comments | « content/browser/download/download_create_info.h ('k') | content/browser/download/download_file.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698