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

Side by Side Diff: chrome/browser/ui/webui/options2/clear_browser_data_handler2.h

Issue 9693032: [uber page] Split up initialization of handlers from initialization of webui pages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: code shuffling Created 8 years, 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_ 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_
7 #pragma once 7 #pragma once
8 8
9 #include "chrome/browser/browsing_data_remover.h" 9 #include "chrome/browser/browsing_data_remover.h"
10 #include "chrome/browser/prefs/pref_member.h" 10 #include "chrome/browser/prefs/pref_member.h"
11 #include "chrome/browser/ui/webui/options2/options_ui2.h" 11 #include "chrome/browser/ui/webui/options2/options_ui2.h"
12 12
13 namespace options2 { 13 namespace options2 {
14 14
15 // Clear browser data handler page UI handler. 15 // Clear browser data handler page UI handler.
16 class ClearBrowserDataHandler : public OptionsPageUIHandler, 16 class ClearBrowserDataHandler : public OptionsPageUIHandler,
17 public BrowsingDataRemover::Observer { 17 public BrowsingDataRemover::Observer {
18 public: 18 public:
19 ClearBrowserDataHandler(); 19 ClearBrowserDataHandler();
20 virtual ~ClearBrowserDataHandler(); 20 virtual ~ClearBrowserDataHandler();
21 21
22 // OptionsPageUIHandler implementation. 22 // OptionsPageUIHandler implementation.
23 virtual void Initialize() OVERRIDE; 23 virtual void InitializeHandler() OVERRIDE;
24 24
25 virtual void GetLocalizedValues(DictionaryValue* localized_strings) OVERRIDE; 25 virtual void GetLocalizedValues(DictionaryValue* localized_strings) OVERRIDE;
26 26
27 // WebUIMessageHandler implementation. 27 // WebUIMessageHandler implementation.
28 virtual void RegisterMessages() OVERRIDE; 28 virtual void RegisterMessages() OVERRIDE;
29 29
30 private: 30 private:
31 // Javascript callback to start clearing data. 31 // Javascript callback to start clearing data.
32 void HandleClearBrowserData(const ListValue* value); 32 void HandleClearBrowserData(const ListValue* value);
33 33
34 // Callback from BrowsingDataRemover. Closes the dialog. 34 // Callback from BrowsingDataRemover. Closes the dialog.
35 virtual void OnBrowsingDataRemoverDone() OVERRIDE; 35 virtual void OnBrowsingDataRemoverDone() OVERRIDE;
36 36
37 // If non-null it means removal is in progress. BrowsingDataRemover takes care 37 // If non-null it means removal is in progress. BrowsingDataRemover takes care
38 // of deleting itself when done. 38 // of deleting itself when done.
39 BrowsingDataRemover* remover_; 39 BrowsingDataRemover* remover_;
40 40
41 // Keeps track of whether clearing LSO data is supported. 41 // Keeps track of whether clearing LSO data is supported.
42 BooleanPrefMember clear_plugin_lso_data_enabled_; 42 BooleanPrefMember clear_plugin_lso_data_enabled_;
43 43
44 DISALLOW_COPY_AND_ASSIGN(ClearBrowserDataHandler); 44 DISALLOW_COPY_AND_ASSIGN(ClearBrowserDataHandler);
45 }; 45 };
46 46
47 } // namespace options2 47 } // namespace options2
48 48
49 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_ 49 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS2_CLEAR_BROWSER_DATA_HANDLER2_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698