OLD | NEW |
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/chromeos/webui/system_info_ui.h" | 5 #include "chrome/browser/chromeos/webui/system_info_ui.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/string_piece.h" | 10 #include "base/string_piece.h" |
11 #include "base/string_util.h" | 11 #include "base/string_util.h" |
12 #include "base/threading/thread.h" | 12 #include "base/threading/thread.h" |
13 #include "base/time.h" | 13 #include "base/time.h" |
14 #include "base/utf_string_conversions.h" | 14 #include "base/utf_string_conversions.h" |
15 #include "base/values.h" | 15 #include "base/values.h" |
16 #include "base/weak_ptr.h" | 16 #include "base/weak_ptr.h" |
17 #include "chrome/browser/browser_thread.h" | |
18 #include "chrome/browser/chromeos/cros/cros_library.h" | 17 #include "chrome/browser/chromeos/cros/cros_library.h" |
19 #include "chrome/browser/chromeos/cros/syslogs_library.h" | 18 #include "chrome/browser/chromeos/cros/syslogs_library.h" |
20 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
21 #include "chrome/browser/tab_contents/tab_contents.h" | |
22 #include "chrome/browser/ui/webui/chrome_url_data_manager.h" | 20 #include "chrome/browser/ui/webui/chrome_url_data_manager.h" |
23 #include "chrome/common/chrome_paths.h" | 21 #include "chrome/common/chrome_paths.h" |
24 #include "chrome/common/jstemplate_builder.h" | 22 #include "chrome/common/jstemplate_builder.h" |
25 #include "chrome/common/url_constants.h" | 23 #include "chrome/common/url_constants.h" |
| 24 #include "content/browser/browser_thread.h" |
| 25 #include "content/browser/tab_contents/tab_contents.h" |
26 #include "grit/browser_resources.h" | 26 #include "grit/browser_resources.h" |
27 #include "grit/chromium_strings.h" | 27 #include "grit/chromium_strings.h" |
28 #include "grit/generated_resources.h" | 28 #include "grit/generated_resources.h" |
29 #include "grit/locale_settings.h" | 29 #include "grit/locale_settings.h" |
30 #include "net/base/directory_lister.h" | 30 #include "net/base/directory_lister.h" |
31 #include "net/base/escape.h" | 31 #include "net/base/escape.h" |
32 #include "ui/base/l10n/l10n_util.h" | 32 #include "ui/base/l10n/l10n_util.h" |
33 #include "ui/base/resource/resource_bundle.h" | 33 #include "ui/base/resource/resource_bundle.h" |
34 | 34 |
35 class SystemInfoUIHTMLSource : public ChromeURLDataManager::DataSource { | 35 class SystemInfoUIHTMLSource : public ChromeURLDataManager::DataSource { |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
176 //////////////////////////////////////////////////////////////////////////////// | 176 //////////////////////////////////////////////////////////////////////////////// |
177 | 177 |
178 SystemInfoUI::SystemInfoUI(TabContents* contents) : WebUI(contents) { | 178 SystemInfoUI::SystemInfoUI(TabContents* contents) : WebUI(contents) { |
179 SystemInfoHandler* handler = new SystemInfoHandler(); | 179 SystemInfoHandler* handler = new SystemInfoHandler(); |
180 AddMessageHandler((handler)->Attach(this)); | 180 AddMessageHandler((handler)->Attach(this)); |
181 SystemInfoUIHTMLSource* html_source = new SystemInfoUIHTMLSource(); | 181 SystemInfoUIHTMLSource* html_source = new SystemInfoUIHTMLSource(); |
182 | 182 |
183 // Set up the chrome://system/ source. | 183 // Set up the chrome://system/ source. |
184 contents->profile()->GetChromeURLDataManager()->AddDataSource(html_source); | 184 contents->profile()->GetChromeURLDataManager()->AddDataSource(html_source); |
185 } | 185 } |
OLD | NEW |