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

Unified Diff: chrome/browser/download/download_item.h

Issue 6932046: Added DownloadProcessHandle class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Moved process_handle_ initializer in DownloadItem constructor. Created 9 years, 7 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: chrome/browser/download/download_item.h
diff --git a/chrome/browser/download/download_item.h b/chrome/browser/download/download_item.h
index 8afd2d2f62c8bc00d36d34ffefd35fbb2dd2c22f..37772a9bb86c2ba7065cc0fc3c8d4e25a6b70595 100644
--- a/chrome/browser/download/download_item.h
+++ b/chrome/browser/download/download_item.h
@@ -25,6 +25,7 @@
#include "base/observer_list.h"
#include "base/time.h"
#include "base/timer.h"
+#include "chrome/browser/download/download_process_handle.h"
#include "googleurl/src/gurl.h"
class DownloadFileManager;
@@ -260,8 +261,6 @@ class DownloadItem {
bool is_paused() const { return is_paused_; }
bool open_when_complete() const { return open_when_complete_; }
void set_open_when_complete(bool open) { open_when_complete_ = open; }
- int render_process_id() const { return render_process_id_; }
- int request_id() const { return request_id_; }
SafetyState safety_state() const { return safety_state_; }
void set_safety_state(SafetyState safety_state) {
safety_state_ = safety_state;
@@ -277,6 +276,10 @@ class DownloadItem {
void set_opened(bool opened) { opened_ = opened; }
bool opened() const { return opened_; }
+ const DownloadProcessHandle& process_handle() const {
+ return process_handle_;
+ }
+
// Returns the final target file path for the download.
FilePath GetTargetFilePath() const;
@@ -386,9 +389,9 @@ class DownloadItem {
// This stores their final target name.
FilePath target_name_;
- // For canceling or pausing requests.
- int render_process_id_;
- int request_id_;
+ // The handle to the process information. Used for operations outside the
+ // download system.
+ DownloadProcessHandle process_handle_;
// True if the item was downloaded as a result of 'save as...'
bool save_as_;

Powered by Google App Engine
This is Rietveld 408576698