OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/dom_ui/system_info_ui.h" | 5 #include "chrome/browser/chromeos/dom_ui/system_info_ui.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | |
9 #include "base/callback.h" | 8 #include "base/callback.h" |
10 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
11 #include "base/path_service.h" | 10 #include "base/path_service.h" |
12 #include "base/string_piece.h" | 11 #include "base/string_piece.h" |
13 #include "base/string_util.h" | 12 #include "base/string_util.h" |
14 #include "base/threading/thread.h" | 13 #include "base/threading/thread.h" |
15 #include "base/time.h" | 14 #include "base/time.h" |
16 #include "base/utf_string_conversions.h" | 15 #include "base/utf_string_conversions.h" |
17 #include "base/values.h" | 16 #include "base/values.h" |
18 #include "base/weak_ptr.h" | 17 #include "base/weak_ptr.h" |
19 #include "chrome/browser/browser_thread.h" | 18 #include "chrome/browser/browser_thread.h" |
20 #include "chrome/browser/chromeos/cros/cros_library.h" | 19 #include "chrome/browser/chromeos/cros/cros_library.h" |
21 #include "chrome/browser/chromeos/cros/syslogs_library.h" | 20 #include "chrome/browser/chromeos/cros/syslogs_library.h" |
22 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" | 21 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" |
23 #include "chrome/common/chrome_paths.h" | 22 #include "chrome/common/chrome_paths.h" |
24 #include "chrome/common/jstemplate_builder.h" | 23 #include "chrome/common/jstemplate_builder.h" |
25 #include "chrome/common/url_constants.h" | 24 #include "chrome/common/url_constants.h" |
26 #include "net/base/escape.h" | 25 #include "net/base/escape.h" |
27 #include "net/base/directory_lister.h" | 26 #include "net/base/directory_lister.h" |
28 #include "grit/browser_resources.h" | 27 #include "grit/browser_resources.h" |
29 #include "grit/chromium_strings.h" | 28 #include "grit/chromium_strings.h" |
30 #include "grit/generated_resources.h" | 29 #include "grit/generated_resources.h" |
31 #include "grit/locale_settings.h" | 30 #include "grit/locale_settings.h" |
| 31 #include "ui/base/resource/resource_bundle.h" |
32 | 32 |
33 class SystemInfoUIHTMLSource : public ChromeURLDataManager::DataSource { | 33 class SystemInfoUIHTMLSource : public ChromeURLDataManager::DataSource { |
34 public: | 34 public: |
35 SystemInfoUIHTMLSource(); | 35 SystemInfoUIHTMLSource(); |
36 | 36 |
37 // Called when the network layer has requested a resource underneath | 37 // Called when the network layer has requested a resource underneath |
38 // the path we registered. | 38 // the path we registered. |
39 virtual void StartDataRequest(const std::string& path, | 39 virtual void StartDataRequest(const std::string& path, |
40 bool is_off_the_record, | 40 bool is_off_the_record, |
41 int request_id); | 41 int request_id); |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 SystemInfoUIHTMLSource* html_source = new SystemInfoUIHTMLSource(); | 179 SystemInfoUIHTMLSource* html_source = new SystemInfoUIHTMLSource(); |
180 | 180 |
181 // Set up the chrome://system/ source. | 181 // Set up the chrome://system/ source. |
182 BrowserThread::PostTask( | 182 BrowserThread::PostTask( |
183 BrowserThread::IO, FROM_HERE, | 183 BrowserThread::IO, FROM_HERE, |
184 NewRunnableMethod( | 184 NewRunnableMethod( |
185 ChromeURLDataManager::GetInstance(), | 185 ChromeURLDataManager::GetInstance(), |
186 &ChromeURLDataManager::AddDataSource, | 186 &ChromeURLDataManager::AddDataSource, |
187 make_scoped_refptr(html_source))); | 187 make_scoped_refptr(html_source))); |
188 } | 188 } |
OLD | NEW |