| Index: components/download/public/download_params.h
|
| diff --git a/components/download/public/download_params.h b/components/download/public/download_params.h
|
| index dcf25b41986ac9b8810ab884e7e21a5c742f9e37..e9885e9e61c478a475378aefa8ba92c4b7d2635f 100644
|
| --- a/components/download/public/download_params.h
|
| +++ b/components/download/public/download_params.h
|
| @@ -102,12 +102,25 @@ struct DownloadParams {
|
| // The DownloadService has too many downloads. Backoff and retry.
|
| BACKOFF,
|
|
|
| - // Failed to create the download. Invalid input parameters.
|
| - BAD_PARAMETERS,
|
| + // The DownloadService has no knowledge of the DownloadClient associated
|
| + // with this request.
|
| + UNEXPECTED_CLIENT,
|
| +
|
| + // Failed to create the download. The guid is already in use.
|
| + UNEXPECTED_GUID,
|
| +
|
| + // The download was cancelled by the Client while it was being persisted.
|
| + CLIENT_CANCELLED,
|
| +
|
| + // The DownloadService was unable to accept and persist this download due to
|
| + // an internal error like the underlying DB store failing to write to disk.
|
| + INTERNAL_ERROR,
|
|
|
| // TODO(dtrainor): Add more error codes.
|
| };
|
|
|
| + using StartCallback = base::Callback<void(const std::string&, StartResult)>;
|
| +
|
| DownloadParams();
|
| DownloadParams(const DownloadParams& other);
|
| ~DownloadParams();
|
| @@ -120,7 +133,7 @@ struct DownloadParams {
|
|
|
| // A callback that will be notified if this download has been accepted and
|
| // persisted by the DownloadService.
|
| - base::Callback<void(const DownloadParams&, StartResult)> callback;
|
| + StartCallback callback;
|
|
|
| // The parameters that determine under what device conditions this download
|
| // will occur.
|
|
|