| 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/dom_ui/options/about_page_handler.h" | 5 #include "chrome/browser/dom_ui/options/about_page_handler.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "app/l10n_util.h" | 9 #include "app/l10n_util.h" |
| 10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 } | 137 } |
| 138 | 138 |
| 139 void AboutPageHandler::GetLocalizedValues(DictionaryValue* localized_strings) { | 139 void AboutPageHandler::GetLocalizedValues(DictionaryValue* localized_strings) { |
| 140 DCHECK(localized_strings); | 140 DCHECK(localized_strings); |
| 141 | 141 |
| 142 LocalizedStrings(localized_strings); | 142 LocalizedStrings(localized_strings); |
| 143 | 143 |
| 144 // browser version | 144 // browser version |
| 145 | 145 |
| 146 chrome::VersionInfo version_info; | 146 chrome::VersionInfo version_info; |
| 147 DCHECK(version_info.is_valid()); | |
| 148 | |
| 149 std::string browser_version = version_info.Version(); | 147 std::string browser_version = version_info.Version(); |
| 150 std::string version_modifier = platform_util::GetVersionStringModifier(); | 148 std::string version_modifier = platform_util::GetVersionStringModifier(); |
| 151 if (!version_modifier.empty()) | 149 if (!version_modifier.empty()) |
| 152 browser_version += " " + version_modifier; | 150 browser_version += " " + version_modifier; |
| 153 | 151 |
| 154 #if !defined(GOOGLE_CHROME_BUILD) | 152 #if !defined(GOOGLE_CHROME_BUILD) |
| 155 browser_version += " ("; | 153 browser_version += " ("; |
| 156 browser_version += version_info.LastChange(); | 154 browser_version += version_info.LastChange(); |
| 157 browser_version += ")"; | 155 browser_version += ")"; |
| 158 #endif | 156 #endif |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 393 | 391 |
| 394 void AboutPageHandler::OnOSVersion(chromeos::VersionLoader::Handle handle, | 392 void AboutPageHandler::OnOSVersion(chromeos::VersionLoader::Handle handle, |
| 395 std::string version) { | 393 std::string version) { |
| 396 if (version.size()) { | 394 if (version.size()) { |
| 397 scoped_ptr<Value> version_string(Value::CreateStringValue(version)); | 395 scoped_ptr<Value> version_string(Value::CreateStringValue(version)); |
| 398 dom_ui_->CallJavascriptFunction(L"AboutPage.updateOSVersionCallback", | 396 dom_ui_->CallJavascriptFunction(L"AboutPage.updateOSVersionCallback", |
| 399 *version_string); | 397 *version_string); |
| 400 } | 398 } |
| 401 } | 399 } |
| 402 #endif | 400 #endif |
| OLD | NEW |