1*2722ceddSAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*2722ceddSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*2722ceddSAndrew Rist * or more contributor license agreements. See the NOTICE file 5*2722ceddSAndrew Rist * distributed with this work for additional information 6*2722ceddSAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*2722ceddSAndrew Rist * to you under the Apache License, Version 2.0 (the 8*2722ceddSAndrew Rist * "License"); you may not use this file except in compliance 9*2722ceddSAndrew Rist * with the License. You may obtain a copy of the License at 10*2722ceddSAndrew Rist * 11*2722ceddSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*2722ceddSAndrew Rist * 13*2722ceddSAndrew Rist * Unless required by applicable law or agreed to in writing, 14*2722ceddSAndrew Rist * software distributed under the License is distributed on an 15*2722ceddSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*2722ceddSAndrew Rist * KIND, either express or implied. See the License for the 17*2722ceddSAndrew Rist * specific language governing permissions and limitations 18*2722ceddSAndrew Rist * under the License. 19*2722ceddSAndrew Rist * 20*2722ceddSAndrew Rist *************************************************************/ 21*2722ceddSAndrew Rist 22*2722ceddSAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove 25cdf0e10cSrcweir #include "precompiled_desktop.hxx" 26cdf0e10cSrcweir 27cdf0e10cSrcweir #include "dp_gui_system.hxx" 28cdf0e10cSrcweir #ifdef WNT 29cdf0e10cSrcweir #define WIN32_LEAN_AND_MEAN 30cdf0e10cSrcweir #ifdef _MSC_VER 31cdf0e10cSrcweir #pragma warning(push,1) /* disable warnings within system headers */ 32cdf0e10cSrcweir #endif 33cdf0e10cSrcweir #include <windows.h> 34cdf0e10cSrcweir #ifdef _MSC_VER 35cdf0e10cSrcweir #pragma warning(pop) 36cdf0e10cSrcweir #endif 37cdf0e10cSrcweir #endif 38cdf0e10cSrcweir 39cdf0e10cSrcweir namespace dp_gui { 40cdf0e10cSrcweir 41cdf0e10cSrcweir //We cannot distinguish Vista and 2008 Server isVista()42cdf0e10cSrcweirbool isVista() 43cdf0e10cSrcweir { 44cdf0e10cSrcweir #ifdef WNT 45cdf0e10cSrcweir OSVERSIONINFO osvi; 46cdf0e10cSrcweir ZeroMemory(&osvi, sizeof(OSVERSIONINFO)); 47cdf0e10cSrcweir osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); 48cdf0e10cSrcweir GetVersionEx(&osvi); 49cdf0e10cSrcweir return osvi.dwMajorVersion >= 6; 50cdf0e10cSrcweir #else 51cdf0e10cSrcweir return false; 52cdf0e10cSrcweir #endif 53cdf0e10cSrcweir } 54cdf0e10cSrcweir 55cdf0e10cSrcweir } //namespace dp_gui 56