OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_WEBSITE_SETTINGS_HANDLER_H_ | |
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_WEBSITE_SETTINGS_HANDLER_H_ | |
7 | |
Dan Beam
2014/07/10 02:57:25
#include <string>
#include "base/macros.h"
#inclu
Daniel Nishi
2014/07/10 19:00:10
Done.
| |
8 #include "chrome/browser/content_settings/host_content_settings_map.h" | |
9 #include "chrome/browser/ui/webui/options/options_ui.h" | |
10 #include "content/public/browser/notification_observer.h" | |
11 #include "content/public/browser/notification_registrar.h" | |
12 | |
13 namespace options { | |
14 | |
15 class WebsiteSettingsHandler : public OptionsPageUIHandler, | |
16 public content::NotificationObserver { | |
17 public: | |
18 WebsiteSettingsHandler(); | |
19 virtual ~WebsiteSettingsHandler(); | |
20 | |
21 // OptionsPageUIHandler implementation. | |
22 virtual void GetLocalizedValues( | |
23 base::DictionaryValue* localized_strings) OVERRIDE; | |
24 virtual void RegisterMessages() OVERRIDE; | |
25 | |
26 // content::NotificationObserver implementation. | |
27 virtual void Observe(int type, | |
28 const content::NotificationSource& source, | |
29 const content::NotificationDetails& details) OVERRIDE; | |
30 | |
31 private: | |
32 // Update the page with all origins for a given Content Setting. | |
Dan Beam
2014/07/10 02:57:24
list what |args| contains in each of these handler
Daniel Nishi
2014/07/10 19:00:10
Done.
| |
33 void UpdateOrigins(const base::ListValue* args); | |
Dan Beam
2014/07/10 02:57:24
nit: if it's chrome.send('messageName') name the C
Daniel Nishi
2014/07/10 19:00:10
Done.
| |
34 | |
35 // Update the page with all origins given a filter string. | |
36 void UpdateSearchResults(const base::ListValue* args); | |
37 | |
Dan Beam
2014/07/10 02:57:25
doc comment
Daniel Nishi
2014/07/10 19:00:10
Done.
| |
38 void UpdateOrigins_(ContentSettingsType content_type, | |
Dan Beam
2014/07/10 02:57:25
no _ at the end for private methods
Daniel Nishi
2014/07/10 19:00:10
Done.
| |
39 const std::string& filter); | |
40 | |
41 ContentSettingsType last_setting_; | |
Dan Beam
2014/07/10 02:57:25
DISALLOW_COPY_AND_ASSIGN(WebsiteSettingsHandler);
Daniel Nishi
2014/07/10 19:00:09
Done.
| |
42 }; | |
43 | |
44 } // namespace options | |
45 | |
46 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_WEBSITE_SETTINGS_HANDLER_H_ | |
OLD | NEW |