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

Side by Side Diff: chrome/browser/ui/webui/cleanup_tool/cleanup_action_handler.h

Issue 2819633003: Cleanup Tool WebUI: Add functionality to the Cleanup button (Closed)
Patch Set: minor cleanups Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "chrome/browser/ui/browser.h"
alito 2017/04/14 00:01:19 Please remove this include.
proberge 2017/04/18 19:24:28 Done.
10 #include "content/public/browser/web_ui_message_handler.h" 11 #include "content/public/browser/web_ui_message_handler.h"
11 12
12 // The handler for Javascript messages related to the "Chrome Cleanup" view. 13 // The handler for Javascript messages related to the "Chrome Cleanup" view.
13 class CleanupActionHandler : public content::WebUIMessageHandler { 14 class CleanupActionHandler : public content::WebUIMessageHandler {
14 public: 15 public:
15 CleanupActionHandler(); 16 CleanupActionHandler();
16 ~CleanupActionHandler() override; 17 ~CleanupActionHandler() override;
17 18
18 // WebUIMessageHandler implementation. 19 // WebUIMessageHandler implementation.
19 void RegisterMessages() override; 20 void RegisterMessages() override;
20 21
21 private: 22 private:
22 void HandleRequestLastScanResult(const base::ListValue* args); 23 void HandleRequestLastScanResult(const base::ListValue* args);
24 void HandleStartCleanup(const base::ListValue* args);
25
26 // Returns the cleanup result initiated by HandleStartCleanup() to the
27 // Javascript caller refererenced by |callback_id|.
28 void ReportCleanupResults(const std::string& callback_id);
23 29
24 DISALLOW_COPY_AND_ASSIGN(CleanupActionHandler); 30 DISALLOW_COPY_AND_ASSIGN(CleanupActionHandler);
25 }; 31 };
26 32
27 #endif // CHROME_BROWSER_UI_WEBUI_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_ 33 #endif // CHROME_BROWSER_UI_WEBUI_CLEANUP_TOOL_CLEANUP_ACTION_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698