drive::DownloadHandler should query DownloadHistory.
commit938f37f79f5d74702420e48210afecfdb210f198
authorasanka@chromium.org <asanka@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 20 May 2014 06:41:21 +0000 (20 06:41 +0000)
committerasanka@chromium.org <asanka@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 20 May 2014 06:41:21 +0000 (20 06:41 +0000)
tree3660c7b3731b4cda320a2f515a854cad89cb925a
parentb72e681f5bcf702e54e52b11bd89954eb098c9f3
drive::DownloadHandler should query DownloadHistory.

The drive::DownloadHandler was using the assumption that all
non-IN_PROGRESS downloads that are created were restored from history.
This is not a safe assumption.

Instead query the DownloadHistory to determine whether a new download
was restored from history or not.

Depends on https://codereview.chromium.org/230103002/ which adds a
WasDownloadRestoredFromHistory method to DownloadHistory.

BUG=7648

Review URL: https://codereview.chromium.org/230133002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271595 0039d316-1c4b-4281-b951-d872f2087c98
chrome/browser/chromeos/drive/download_handler.cc