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

Side by Side Diff: chrome/browser/ui/webui/local_state/local_state_ui.h

Issue 1910323002: Allow whitelisted prefs to be displayed in ChromeOS in chrome://local-state. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | chrome/browser/ui/webui/local_state/local_state_ui.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 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_LOCAL_STATE_LOCAL_STATE_UI_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_LOCAL_STATE_LOCAL_STATE_UI_H_
6 #define CHROME_BROWSER_UI_WEBUI_LOCAL_STATE_LOCAL_STATE_UI_H_ 6 #define CHROME_BROWSER_UI_WEBUI_LOCAL_STATE_LOCAL_STATE_UI_H_
7 7
8 #include <string>
9 #include <vector>
10
8 #include "base/macros.h" 11 #include "base/macros.h"
9 #include "content/public/browser/web_ui_controller.h" 12 #include "content/public/browser/web_ui_controller.h"
10 13
14 namespace base {
15 class DictionaryValue;
16 }
17
18 // Namespace for exposing the method for unit tests.
19 namespace internal {
20
21 // Removes elements from |prefs| where the key does not match any of the
22 // prefixes in |valid_prefixes|.
23 void FilterPrefs(const std::vector<std::string>& valid_prefixes,
24 base::DictionaryValue* prefs);
25
26 } // namespace internal
27
11 // Controller for chrome://local-state/ page. 28 // Controller for chrome://local-state/ page.
12 class LocalStateUI : public content::WebUIController { 29 class LocalStateUI : public content::WebUIController {
13 public: 30 public:
14 explicit LocalStateUI(content::WebUI* web_ui); 31 explicit LocalStateUI(content::WebUI* web_ui);
15 ~LocalStateUI() override; 32 ~LocalStateUI() override;
16 33
17 private: 34 private:
18 DISALLOW_COPY_AND_ASSIGN(LocalStateUI); 35 DISALLOW_COPY_AND_ASSIGN(LocalStateUI);
19 }; 36 };
20 37
21 #endif // CHROME_BROWSER_UI_WEBUI_LOCAL_STATE_LOCAL_STATE_UI_H_ 38 #endif // CHROME_BROWSER_UI_WEBUI_LOCAL_STATE_LOCAL_STATE_UI_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/webui/local_state/local_state_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698