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

Side by Side Diff: chrome/browser/ui/webui/offline/offline_internals_ui_message_handler.h

Issue 2473553004: Request Picker task (Closed)
Patch Set: Missed a few places to convert back, take another merge Created 4 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H_
7 7
8 #include "base/memory/weak_ptr.h" 8 #include "base/memory/weak_ptr.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "components/offline_pages/background/request_coordinator.h" 10 #include "components/offline_pages/background/request_coordinator.h"
11 #include "components/offline_pages/background/request_queue_results.h"
11 #include "components/offline_pages/background/save_page_request.h" 12 #include "components/offline_pages/background/save_page_request.h"
12 #include "components/offline_pages/offline_page_model.h" 13 #include "components/offline_pages/offline_page_model.h"
13 #include "components/offline_pages/offline_store_types.h" 14 #include "components/offline_pages/offline_store_types.h"
14 #include "content/public/browser/web_ui_message_handler.h" 15 #include "content/public/browser/web_ui_message_handler.h"
15 16
16 namespace offline_internals { 17 namespace offline_internals {
17 18
18 // Class acting as a controller of the chrome://offline-internals WebUI. 19 // Class acting as a controller of the chrome://offline-internals WebUI.
19 class OfflineInternalsUIMessageHandler : public content::WebUIMessageHandler { 20 class OfflineInternalsUIMessageHandler : public content::WebUIMessageHandler {
20 public: 21 public:
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 void HandleGetNetworkStatus(const base::ListValue* args); 57 void HandleGetNetworkStatus(const base::ListValue* args);
57 58
58 // Callback for async GetAllPages calls. 59 // Callback for async GetAllPages calls.
59 void HandleStoredPagesCallback( 60 void HandleStoredPagesCallback(
60 std::string callback_id, 61 std::string callback_id,
61 const offline_pages::MultipleOfflinePageItemResult& pages); 62 const offline_pages::MultipleOfflinePageItemResult& pages);
62 63
63 // Callback for async GetRequests calls. 64 // Callback for async GetRequests calls.
64 void HandleRequestQueueCallback( 65 void HandleRequestQueueCallback(
65 std::string callback_id, 66 std::string callback_id,
66 offline_pages::RequestQueue::GetRequestsResult result, 67 offline_pages::GetRequestsResult result,
Evan Stade 2016/11/09 00:43:03 wait a second, enum class lets you forward declare
Pete Williamson 2016/11/09 00:55:29 Done.
67 std::vector<std::unique_ptr<offline_pages::SavePageRequest>> requests); 68 std::vector<std::unique_ptr<offline_pages::SavePageRequest>> requests);
68 69
69 // Callback for DeletePage/DeleteAllPages calls. 70 // Callback for DeletePage/DeleteAllPages calls.
70 void HandleDeletedPagesCallback(std::string callback_id, 71 void HandleDeletedPagesCallback(std::string callback_id,
71 const offline_pages::DeletePageResult result); 72 const offline_pages::DeletePageResult result);
72 73
73 // Callback for DeleteRequest/DeleteAllRequests calls. 74 // Callback for DeleteRequest/DeleteAllRequests calls.
74 void HandleDeletedRequestsCallback( 75 void HandleDeletedRequestsCallback(
75 std::string callback_id, 76 std::string callback_id,
76 const offline_pages::MultipleItemStatuses& results); 77 const offline_pages::MultipleItemStatuses& results);
(...skipping 17 matching lines...) Expand all
94 95
95 // Factory for creating references in callbacks. 96 // Factory for creating references in callbacks.
96 base::WeakPtrFactory<OfflineInternalsUIMessageHandler> weak_ptr_factory_; 97 base::WeakPtrFactory<OfflineInternalsUIMessageHandler> weak_ptr_factory_;
97 98
98 DISALLOW_COPY_AND_ASSIGN(OfflineInternalsUIMessageHandler); 99 DISALLOW_COPY_AND_ASSIGN(OfflineInternalsUIMessageHandler);
99 }; 100 };
100 101
101 } // namespace offline_internals 102 } // namespace offline_internals
102 103
103 #endif // CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H _ 104 #endif // CHROME_BROWSER_UI_WEBUI_OFFLINE_OFFLINE_INTERNALS_UI_MESSAGE_HANDLER_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698