[1/3] wbemprox: Implement more properties of Win32_OperatingSystem.
Hans Leidekker
hans at codeweavers.com
Thu May 2 05:02:06 CDT 2013
See http://bugs.winehq.org/show_bug.cgi?id=33504
---
dlls/wbemprox/builtin.c | 49 +++++++++++++++++++++++++++++++++++------------
1 file changed, 37 insertions(+), 12 deletions(-)
diff --git a/dlls/wbemprox/builtin.c b/dlls/wbemprox/builtin.c
index 8b3e3c3..2106f67 100644
--- a/dlls/wbemprox/builtin.c
+++ b/dlls/wbemprox/builtin.c
@@ -163,6 +163,10 @@ static const WCHAR prop_osarchitectureW[] =
{'O','S','A','r','c','h','i','t','e','c','t','u','r','e',0};
static const WCHAR prop_oslanguageW[] =
{'O','S','L','a','n','g','u','a','g','e',0};
+static const WCHAR prop_osproductsuiteW[] =
+ {'O','S','P','r','o','d','u','c','t','S','u','i','t','e',0};
+static const WCHAR prop_ostypeW[] =
+ {'O','S','T','y','p','e',0};
static const WCHAR prop_parameterW[] =
{'P','a','r','a','m','e','t','e','r',0};
static const WCHAR prop_pnpdeviceidW[] =
@@ -179,6 +183,8 @@ static const WCHAR prop_releasedateW[] =
{'R','e','l','e','a','s','e','D','a','t','e',0};
static const WCHAR prop_serialnumberW[] =
{'S','e','r','i','a','l','N','u','m','b','e','r',0};
+static const WCHAR prop_servicepackmajorW[] =
+ {'S','e','r','v','i','c','e','P','a','c','k','M','a','j','o','r','V','e','r','s','i','o','n',0};
static const WCHAR prop_servicetypeW[] =
{'S','e','r','v','i','c','e','T','y','p','e',0};
static const WCHAR prop_startmodeW[] =
@@ -193,6 +199,8 @@ static const WCHAR prop_stateW[] =
{'S','t','a','t','e',0};
static const WCHAR prop_strvalueW[] =
{'S','t','r','i','n','g','V','a','l','u','e',0};
+static const WCHAR prop_suitemaskW[] =
+ {'S','u','i','t','e','M','a','s','k',0};
static const WCHAR prop_systemdirectoryW[] =
{'S','y','s','t','e','m','D','i','r','e','c','t','o','r','y',0};
static const WCHAR prop_systemnameW[] =
@@ -288,12 +296,17 @@ static const struct column col_networkadapter[] =
};
static const struct column col_os[] =
{
- { prop_captionW, CIM_STRING },
- { prop_csdversionW, CIM_STRING },
- { prop_lastbootuptimeW, CIM_DATETIME|COL_FLAG_DYNAMIC },
- { prop_osarchitectureW, CIM_STRING },
- { prop_oslanguageW, CIM_UINT32, VT_I4 },
- { prop_systemdirectoryW, CIM_STRING|COL_FLAG_DYNAMIC }
+ { prop_captionW, CIM_STRING },
+ { prop_csdversionW, CIM_STRING },
+ { prop_lastbootuptimeW, CIM_DATETIME|COL_FLAG_DYNAMIC },
+ { prop_osarchitectureW, CIM_STRING },
+ { prop_oslanguageW, CIM_UINT32, VT_I4 },
+ { prop_osproductsuiteW, CIM_UINT32, VT_I4 },
+ { prop_ostypeW, CIM_UINT16, VT_I4 },
+ { prop_servicepackmajorW, CIM_UINT16, VT_I4 },
+ { prop_suitemaskW, CIM_UINT32, VT_I4 },
+ { prop_systemdirectoryW, CIM_STRING|COL_FLAG_DYNAMIC },
+ { prop_versionW, CIM_STRING }
};
static const struct column col_param[] =
{
@@ -429,6 +442,8 @@ static const WCHAR os_32bitW[] =
{'3','2','-','b','i','t',0};
static const WCHAR os_64bitW[] =
{'6','4','-','b','i','t',0};
+static const WCHAR os_versionW[] =
+ {'5','.','1','.','2','6','0','0',0};
static const WCHAR sounddevice_productnameW[] =
{'W','i','n','e',' ','A','u','d','i','o',' ','D','e','v','i','c','e',0};
static const WCHAR videocontroller_deviceidW[] =
@@ -515,7 +530,12 @@ struct record_operatingsystem
const WCHAR *lastbootuptime;
const WCHAR *osarchitecture;
UINT32 oslanguage;
+ UINT32 osproductsuite;
+ UINT16 ostype;
+ UINT16 servicepackmajor;
+ UINT32 suitemask;
const WCHAR *systemdirectory;
+ const WCHAR *version;
};
struct record_param
{
@@ -1178,12 +1198,17 @@ static void fill_os( struct table *table )
if (!(table->data = heap_alloc( sizeof(*rec) ))) return;
rec = (struct record_operatingsystem *)table->data;
- rec->caption = os_captionW;
- rec->csdversion = os_csdversionW;
- rec->lastbootuptime = get_lastbootuptime();
- rec->osarchitecture = get_osarchitecture();
- rec->oslanguage = MAKELANGID( LANG_ENGLISH, SUBLANG_ENGLISH_US );
- rec->systemdirectory = get_systemdirectory();
+ rec->caption = os_captionW;
+ rec->csdversion = os_csdversionW;
+ rec->lastbootuptime = get_lastbootuptime();
+ rec->osarchitecture = get_osarchitecture();
+ rec->oslanguage = MAKELANGID( LANG_ENGLISH, SUBLANG_ENGLISH_US );
+ rec->osproductsuite = 2461140; /* Windows XP Professional */
+ rec->ostype = 18; /* WINNT */
+ rec->servicepackmajor = 3;
+ rec->suitemask = 272; /* Single User + Terminal */
+ rec->systemdirectory = get_systemdirectory();
+ rec->version = os_versionW;
TRACE("created 1 row\n");
table->num_rows = 1;
--
1.7.10.4
More information about the wine-patches
mailing list