Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
791aa538
Commit
791aa538
authored
Apr 03, 2011
by
Andrew Nguyen
Committed by
Alexandre Julliard
Apr 04, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dxdiagn: Add a physical memory display string property to the DxDiag_SystemInfo container.
parent
bd7ad13b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
provider.c
dlls/dxdiagn/provider.c
+10
-1
container.c
dlls/dxdiagn/tests/container.c
+2
-0
No files found.
dlls/dxdiagn/provider.c
View file @
791aa538
...
...
@@ -533,14 +533,17 @@ static HRESULT build_systeminfo_tree(IDxDiagContainerImpl_Container *node)
static
const
WCHAR
dwOSBuildNumber
[]
=
{
'd'
,
'w'
,
'O'
,
'S'
,
'B'
,
'u'
,
'i'
,
'l'
,
'd'
,
'N'
,
'u'
,
'm'
,
'b'
,
'e'
,
'r'
,
0
};
static
const
WCHAR
dwOSPlatformID
[]
=
{
'd'
,
'w'
,
'O'
,
'S'
,
'P'
,
'l'
,
'a'
,
't'
,
'f'
,
'o'
,
'r'
,
'm'
,
'I'
,
'D'
,
0
};
static
const
WCHAR
szCSDVersion
[]
=
{
's'
,
'z'
,
'C'
,
'S'
,
'D'
,
'V'
,
'e'
,
'r'
,
's'
,
'i'
,
'o'
,
'n'
,
0
};
static
const
WCHAR
szPhysicalMemoryEnglish
[]
=
{
's'
,
'z'
,
'P'
,
'h'
,
'y'
,
's'
,
'i'
,
'c'
,
'a'
,
'l'
,
'M'
,
'e'
,
'm'
,
'o'
,
'r'
,
'y'
,
'E'
,
'n'
,
'g'
,
'l'
,
'i'
,
's'
,
'h'
,
0
};
static
const
WCHAR
szMachineNameLocalized
[]
=
{
's'
,
'z'
,
'M'
,
'a'
,
'c'
,
'h'
,
'i'
,
'n'
,
'e'
,
'N'
,
'a'
,
'm'
,
'e'
,
'L'
,
'o'
,
'c'
,
'a'
,
'l'
,
'i'
,
'z'
,
'e'
,
'd'
,
0
};
static
const
WCHAR
szMachineNameEnglish
[]
=
{
's'
,
'z'
,
'M'
,
'a'
,
'c'
,
'h'
,
'i'
,
'n'
,
'e'
,
'N'
,
'a'
,
'm'
,
'e'
,
'E'
,
'n'
,
'g'
,
'l'
,
'i'
,
's'
,
'h'
,
0
};
static
const
WCHAR
physmem_fmtW
[]
=
{
'%'
,
'u'
,
'M'
,
'B'
,
' '
,
'R'
,
'A'
,
'M'
,
0
};
HRESULT
hr
;
MEMORYSTATUSEX
msex
;
OSVERSIONINFOW
info
;
DWORD
count
;
WCHAR
buffer
[
MAX_PATH
],
computer_name
[
MAX_COMPUTERNAME_LENGTH
+
1
];
WCHAR
buffer
[
MAX_PATH
],
computer_name
[
MAX_COMPUTERNAME_LENGTH
+
1
]
,
print_buf
[
200
]
;
hr
=
add_ui4_property
(
node
,
dwDirectXVersionMajor
,
9
);
if
(
FAILED
(
hr
))
...
...
@@ -612,6 +615,12 @@ static HRESULT build_systeminfo_tree(IDxDiagContainerImpl_Container *node)
if
(
FAILED
(
hr
))
return
hr
;
/* FIXME: Roundoff should not be done with truncated division. */
snprintfW
(
print_buf
,
sizeof
(
print_buf
)
/
sizeof
(
WCHAR
),
physmem_fmtW
,
(
DWORD
)(
msex
.
ullTotalPhys
/
(
1024
*
1024
)));
hr
=
add_bstr_property
(
node
,
szPhysicalMemoryEnglish
,
print_buf
);
if
(
FAILED
(
hr
))
return
hr
;
GetWindowsDirectoryW
(
buffer
,
MAX_PATH
);
hr
=
add_bstr_property
(
node
,
szWindowsDir
,
buffer
);
...
...
dlls/dxdiagn/tests/container.c
View file @
791aa538
...
...
@@ -788,6 +788,7 @@ static void test_DxDiag_SystemInfo(void)
static
const
WCHAR
szLanguagesEnglish
[]
=
{
's'
,
'z'
,
'L'
,
'a'
,
'n'
,
'g'
,
'u'
,
'a'
,
'g'
,
'e'
,
's'
,
'E'
,
'n'
,
'g'
,
'l'
,
'i'
,
's'
,
'h'
,
0
};
static
const
WCHAR
szTimeLocalized
[]
=
{
's'
,
'z'
,
'T'
,
'i'
,
'm'
,
'e'
,
'L'
,
'o'
,
'c'
,
'a'
,
'l'
,
'i'
,
'z'
,
'e'
,
'd'
,
0
};
static
const
WCHAR
szTimeEnglish
[]
=
{
's'
,
'z'
,
'T'
,
'i'
,
'm'
,
'e'
,
'E'
,
'n'
,
'g'
,
'l'
,
'i'
,
's'
,
'h'
,
0
};
static
const
WCHAR
szPhysicalMemoryEnglish
[]
=
{
's'
,
'z'
,
'P'
,
'h'
,
'y'
,
's'
,
'i'
,
'c'
,
'a'
,
'l'
,
'M'
,
'e'
,
'm'
,
'o'
,
'r'
,
'y'
,
'E'
,
'n'
,
'g'
,
'l'
,
'i'
,
's'
,
'h'
,
0
};
static
const
struct
{
...
...
@@ -818,6 +819,7 @@ static void test_DxDiag_SystemInfo(void)
{
szLanguagesEnglish
,
VT_BSTR
},
{
szTimeLocalized
,
VT_BSTR
},
{
szTimeEnglish
,
VT_BSTR
},
{
szPhysicalMemoryEnglish
,
VT_BSTR
},
};
HRESULT
hr
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment