| Index: components/offline_pages/background/offliner.h
|
| diff --git a/components/offline_pages/background/offliner.h b/components/offline_pages/background/offliner.h
|
| index 8bc6468af55a0f51565c935886665af2bb3cb7a0..7370091d5eb463454c5a463565637a3448dfc6fd 100644
|
| --- a/components/offline_pages/background/offliner.h
|
| +++ b/components/offline_pages/background/offliner.h
|
| @@ -5,6 +5,8 @@
|
| #ifndef COMPONENTS_OFFLINE_PAGES_BACKGROUND_OFFLINER_H_
|
| #define COMPONENTS_OFFLINE_PAGES_BACKGROUND_OFFLINER_H_
|
|
|
| +#include <string>
|
| +
|
| #include "base/callback.h"
|
|
|
| namespace offline_pages {
|
| @@ -39,6 +41,22 @@ class Offliner {
|
| STATUS_COUNT
|
| };
|
|
|
| + static std::string RequestStatusToString(RequestStatus request_status) {
|
| + switch (request_status) {
|
| + case UNKNOWN: return "UNKNOWN";
|
| + case LOADED: return "LOADED";
|
| + case SAVED: return "SAVED";
|
| + case REQUEST_COORDINATOR_CANCELED: return "REQUEST_COORDINATOR_CANCELED";
|
| + case PRERENDERING_CANCELED: return "PRERENDERING_CANCELED";
|
| + case PRERENDERING_FAILED: return "PRERENDERING_FAILED";
|
| + case SAVE_FAILED: return "SAVE_FAILED";
|
| + case FOREGROUND_CANCELED: return "FOREGROUND_CANCELED";
|
| + default:
|
| + DCHECK(false);
|
| + return "";
|
| + }
|
| + }
|
| +
|
| // Reports the completion status of a request.
|
| // TODO(dougarnett): consider passing back a request id instead of request.
|
| typedef base::Callback<void(const SavePageRequest&, RequestStatus)>
|
|
|