+ OSVERSIONINFO info;
+ wxZeroMemory(info);
+ info.dwOSVersionInfoSize = sizeof(info);
+ if ( ::GetVersionEx(&info) )
+ {
+ s_version.initialized = true;
+
+#if defined(__WXWINCE__)
+ s_version.os = wxOS_WINDOWS_CE;
+#elif defined(__WXMICROWIN__)
+ s_version.os = wxOS_WINDOWS_MICRO;
+#else // "normal" desktop Windows system, use run-time detection
+ switch ( info.dwPlatformId )
+ {
+ case VER_PLATFORM_WIN32_NT:
+ s_version.os = wxOS_WINDOWS_NT;
+ break;
+
+ case VER_PLATFORM_WIN32_WINDOWS:
+ s_version.os = wxOS_WINDOWS_9X;
+ break;
+ }
+#endif // Windows versions
+
+ s_version.verMaj = info.dwMajorVersion;
+ s_version.verMin = info.dwMinorVersion;
+ }
+ else // GetVersionEx() failed
+ {
+ s_version.initialized = -1;
+ }