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

Unified Diff: chrome/renderer/localized_error.cc

Issue 7150018: Use GetVersion for Windows run-time version checks in preference to OperatingSystemVersionNumbers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/fullscreen_win.cc ('k') | chrome_frame/dll_redirector.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/localized_error.cc
===================================================================
--- chrome/renderer/localized_error.cc (revision 89028)
+++ chrome/renderer/localized_error.cc (working copy)
@@ -8,7 +8,6 @@
#include "base/logging.h"
#include "base/string16.h"
#include "base/string_number_conversions.h"
-#include "base/sys_info.h"
#include "base/utf_string_conversions.h"
#include "base/values.h"
#include "chrome/common/extensions/extension_set.h"
@@ -21,6 +20,10 @@
#include "ui/base/l10n/l10n_util.h"
#include "webkit/glue/webkit_glue.h"
+#if defined(OS_WIN)
+#include "base/win/windows_version.h"
+#endif
+
using WebKit::WebURLError;
namespace {
@@ -442,14 +445,12 @@
IDS_ERRORPAGES_SUMMARY_INTERNET_DISCONNECTED_PLATFORM;
#if defined(OS_WIN)
// Different versions of Windows have different instructions.
- int32 major_version, minor_version, bugfix_version;
- base::SysInfo::OperatingSystemVersionNumbers(
- &major_version, &minor_version, &bugfix_version);
- if (major_version < 6) {
+ base::win::Version windows_version = base::win::GetVersion();
+ if (windows_version < base::win::VERSION_VISTA) {
// XP, XP64, and Server 2003.
platform_string_id =
IDS_ERRORPAGES_SUMMARY_INTERNET_DISCONNECTED_PLATFORM_XP;
- } else if (major_version == 6 && minor_version == 0) {
+ } else if (windows_version == base::win::VERSION_VISTA) {
// Vista
platform_string_id =
IDS_ERRORPAGES_SUMMARY_INTERNET_DISCONNECTED_PLATFORM_VISTA;
« no previous file with comments | « chrome/browser/fullscreen_win.cc ('k') | chrome_frame/dll_redirector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698