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

Side by Side Diff: chrome/browser/ui/webui/options/options_ui.cc

Issue 7033018: Handler settings page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove in_unit_test_ Created 9 years, 7 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
« no previous file with comments | « chrome/browser/ui/webui/options/handler_options_handler.cc ('k') | chrome/chrome_browser.gypi » ('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 (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 #include "chrome/browser/ui/webui/options/options_ui.h" 5 #include "chrome/browser/ui/webui/options/options_ui.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "base/command_line.h" 11 #include "base/command_line.h"
12 #include "base/memory/singleton.h" 12 #include "base/memory/singleton.h"
13 #include "base/message_loop.h" 13 #include "base/message_loop.h"
14 #include "base/string_piece.h" 14 #include "base/string_piece.h"
15 #include "base/string_util.h" 15 #include "base/string_util.h"
16 #include "base/threading/thread.h" 16 #include "base/threading/thread.h"
17 #include "base/time.h" 17 #include "base/time.h"
18 #include "base/values.h" 18 #include "base/values.h"
19 #include "chrome/browser/browser_about_handler.h" 19 #include "chrome/browser/browser_about_handler.h"
20 #include "chrome/browser/profiles/profile.h" 20 #include "chrome/browser/profiles/profile.h"
21 #include "chrome/browser/ui/webui/options/about_page_handler.h" 21 #include "chrome/browser/ui/webui/options/about_page_handler.h"
22 #include "chrome/browser/ui/webui/options/advanced_options_handler.h" 22 #include "chrome/browser/ui/webui/options/advanced_options_handler.h"
23 #include "chrome/browser/ui/webui/options/autofill_options_handler.h" 23 #include "chrome/browser/ui/webui/options/autofill_options_handler.h"
24 #include "chrome/browser/ui/webui/options/browser_options_handler.h" 24 #include "chrome/browser/ui/webui/options/browser_options_handler.h"
25 #include "chrome/browser/ui/webui/options/clear_browser_data_handler.h" 25 #include "chrome/browser/ui/webui/options/clear_browser_data_handler.h"
26 #include "chrome/browser/ui/webui/options/content_settings_handler.h" 26 #include "chrome/browser/ui/webui/options/content_settings_handler.h"
27 #include "chrome/browser/ui/webui/options/handler_options_handler.h"
27 #include "chrome/browser/ui/webui/options/cookies_view_handler.h" 28 #include "chrome/browser/ui/webui/options/cookies_view_handler.h"
28 #include "chrome/browser/ui/webui/options/core_options_handler.h" 29 #include "chrome/browser/ui/webui/options/core_options_handler.h"
29 #include "chrome/browser/ui/webui/options/font_settings_handler.h" 30 #include "chrome/browser/ui/webui/options/font_settings_handler.h"
30 #include "chrome/browser/ui/webui/options/import_data_handler.h" 31 #include "chrome/browser/ui/webui/options/import_data_handler.h"
31 #include "chrome/browser/ui/webui/options/language_options_handler.h" 32 #include "chrome/browser/ui/webui/options/language_options_handler.h"
32 #include "chrome/browser/ui/webui/options/password_manager_handler.h" 33 #include "chrome/browser/ui/webui/options/password_manager_handler.h"
33 #include "chrome/browser/ui/webui/options/personal_options_handler.h" 34 #include "chrome/browser/ui/webui/options/personal_options_handler.h"
34 #include "chrome/browser/ui/webui/options/search_engine_manager_handler.h" 35 #include "chrome/browser/ui/webui/options/search_engine_manager_handler.h"
35 #include "chrome/browser/ui/webui/options/stop_syncing_handler.h" 36 #include "chrome/browser/ui/webui/options/stop_syncing_handler.h"
36 #include "chrome/browser/ui/webui/options/sync_setup_handler.h" 37 #include "chrome/browser/ui/webui/options/sync_setup_handler.h"
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 AddOptionsPageUIHandler(localized_strings, new chromeos::ProxyHandler()); 254 AddOptionsPageUIHandler(localized_strings, new chromeos::ProxyHandler());
254 AddOptionsPageUIHandler(localized_strings, 255 AddOptionsPageUIHandler(localized_strings,
255 new chromeos::ChangePictureOptionsHandler()); 256 new chromeos::ChangePictureOptionsHandler());
256 AddOptionsPageUIHandler(localized_strings, 257 AddOptionsPageUIHandler(localized_strings,
257 new chromeos::StatsOptionsHandler()); 258 new chromeos::StatsOptionsHandler());
258 AddOptionsPageUIHandler(localized_strings, new SystemOptionsHandler()); 259 AddOptionsPageUIHandler(localized_strings, new SystemOptionsHandler());
259 #endif 260 #endif
260 #if defined(USE_NSS) 261 #if defined(USE_NSS)
261 AddOptionsPageUIHandler(localized_strings, new CertificateManagerHandler()); 262 AddOptionsPageUIHandler(localized_strings, new CertificateManagerHandler());
262 #endif 263 #endif
264 AddOptionsPageUIHandler(localized_strings, new HandlerOptionsHandler());
263 265
264 // |localized_strings| ownership is taken over by this constructor. 266 // |localized_strings| ownership is taken over by this constructor.
265 OptionsUIHTMLSource* html_source = 267 OptionsUIHTMLSource* html_source =
266 new OptionsUIHTMLSource(localized_strings); 268 new OptionsUIHTMLSource(localized_strings);
267 269
268 // Set up the chrome://settings/ source. 270 // Set up the chrome://settings/ source.
269 contents->profile()->GetChromeURLDataManager()->AddDataSource(html_source); 271 contents->profile()->GetChromeURLDataManager()->AddDataSource(html_source);
270 272
271 // Set up the chrome://theme/ source. 273 // Set up the chrome://theme/ source.
272 ThemeSource* theme = new ThemeSource(contents->profile()); 274 ThemeSource* theme = new ThemeSource(contents->profile());
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 OptionsPageUIHandler* handler_raw) { 352 OptionsPageUIHandler* handler_raw) {
351 scoped_ptr<OptionsPageUIHandler> handler(handler_raw); 353 scoped_ptr<OptionsPageUIHandler> handler(handler_raw);
352 DCHECK(handler.get()); 354 DCHECK(handler.get());
353 // Add only if handler's service is enabled. 355 // Add only if handler's service is enabled.
354 if (handler->IsEnabled()) { 356 if (handler->IsEnabled()) {
355 handler->GetLocalizedValues(localized_strings); 357 handler->GetLocalizedValues(localized_strings);
356 // Add handler to the list and also pass the ownership. 358 // Add handler to the list and also pass the ownership.
357 AddMessageHandler(handler.release()->Attach(this)); 359 AddMessageHandler(handler.release()->Attach(this));
358 } 360 }
359 } 361 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/options/handler_options_handler.cc ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698