ReactOS
0.4.16-dev-555-g690643f
Toggle main menu visibility
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Functions
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Variables
_
c
d
e
f
g
h
i
l
m
n
o
p
s
t
u
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
_
a
b
c
d
f
i
l
m
o
p
s
t
w
x
Enumerator
a
b
c
d
e
f
g
h
i
m
n
o
p
r
s
t
u
v
w
x
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
h
i
k
l
m
n
o
p
r
s
t
u
v
w
z
Enumerator
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Related Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
x
Files
File List
File Members
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Examples
NtUserGetClassInfo.c
Go to the documentation of this file.
1
/*
2
* PROJECT: ReactOS api tests
3
* LICENSE: GPL - See COPYING in the top level directory
4
* PURPOSE: Test for NtUserGetClassInfo
5
* PROGRAMMERS:
6
*/
7
8
#include "../win32nt.h"
9
10
START_TEST
(
NtUserGetClassInfo
)
11
{
12
HINSTANCE
hinst
=
GetModuleHandle
(
NULL
);
13
WNDCLASSEXW
wclex, wclex2 = {0};
14
UNICODE_STRING
us
;
15
PWSTR
pwstr =
NULL
;
16
17
#ifdef _M_AMD64
18
skip
(
"Test is broken on x64.\n"
);
19
return
;
20
#endif
21
22
us
.Length = 8;
23
us
.MaximumLength = 8;
24
us
.Buffer =
L
"test"
;
25
26
wclex.
cbSize
=
sizeof
(
WNDCLASSEXW
);
27
wclex.
style
= 0;
28
wclex.
lpfnWndProc
=
NULL
;
29
wclex.
cbClsExtra
= 2;
30
wclex.
cbWndExtra
= 4;
31
wclex.
hInstance
=
hinst
;
32
wclex.
hIcon
=
NULL
;
33
wclex.
hCursor
=
NULL
;
34
wclex.
hbrBackground
=
CreateSolidBrush
(
RGB
(4,7,5));
35
wclex.
lpszMenuName
=
L
"MyMenu"
;
36
wclex.
lpszClassName
=
us
.Buffer;
37
wclex.
hIconSm
=
NULL
;
38
39
ASSERT
(
RegisterClassExW
(&wclex) != 0);
40
41
TEST
(
GetClassInfoExW
(
hinst
,
us
.Buffer, &wclex) != 0);
42
wclex2.
cbSize
=
sizeof
(
WNDCLASSEXW
);
43
TEST
(
NtUserGetClassInfo
(
hinst
, &
us
, &wclex2, &pwstr, 0) != 0);
44
45
TEST
(pwstr == wclex.
lpszMenuName
);
46
TEST
(wclex2.
cbSize
== wclex.
cbSize
);
47
TEST
(wclex2.
style
== wclex.
style
);
48
TEST
(wclex2.
lpfnWndProc
== wclex.
lpfnWndProc
);
49
TEST
(wclex2.
cbClsExtra
== wclex.
cbClsExtra
);
50
TEST
(wclex2.
cbWndExtra
== wclex.
cbWndExtra
);
51
TEST
(wclex2.
hInstance
== wclex.
hInstance
);
52
TEST
(wclex2.
hIcon
== wclex.
hIcon
);
53
TEST
(wclex2.
hCursor
== wclex.
hCursor
);
54
TEST
(wclex2.
hbrBackground
== wclex.
hbrBackground
);
55
TEST
(wclex2.
lpszMenuName
== 0);
56
TEST
(wclex2.
lpszClassName
== 0);
57
TEST
(wclex2.
hIconSm
== wclex.
hIconSm
);
58
59
}
skip
#define skip(...)
Definition:
atltest.h:64
START_TEST
#define START_TEST(x)
Definition:
atltest.h:75
NULL
#define NULL
Definition:
types.h:112
RGB
#define RGB(r, g, b)
Definition:
precomp.h:71
NtUserGetClassInfo
BOOL NTAPI NtUserGetClassInfo(HINSTANCE hInstance, PUNICODE_STRING ClassName, LPWNDCLASSEXW wcex, LPWSTR *ppszMenuName, BOOL Ansi)
Definition:
class.c:2779
void
Definition:
nsiface.idl:2307
ASSERT
#define ASSERT(a)
Definition:
mode.c:44
TEST
#define TEST(x)
Definition:
precomp.h:20
hinst
static HINSTANCE hinst
Definition:
edit.c:551
us
static const BYTE us[]
Definition:
encode.c:689
L
#define L(x)
Definition:
ntvdm.h:50
_UNICODE_STRING
Definition:
env_spec_w32.h:368
_WNDCLASSEXW
Definition:
winuser.h:3218
_WNDCLASSEXW::lpszClassName
LPCWSTR lpszClassName
Definition:
winuser.h:3229
_WNDCLASSEXW::lpszMenuName
LPCWSTR lpszMenuName
Definition:
winuser.h:3228
_WNDCLASSEXW::hbrBackground
HBRUSH hbrBackground
Definition:
winuser.h:3227
_WNDCLASSEXW::lpfnWndProc
WNDPROC lpfnWndProc
Definition:
winuser.h:3221
_WNDCLASSEXW::cbSize
UINT cbSize
Definition:
winuser.h:3219
_WNDCLASSEXW::cbWndExtra
int cbWndExtra
Definition:
winuser.h:3223
_WNDCLASSEXW::hCursor
HCURSOR hCursor
Definition:
winuser.h:3226
_WNDCLASSEXW::hIconSm
HICON hIconSm
Definition:
winuser.h:3230
_WNDCLASSEXW::hInstance
HINSTANCE hInstance
Definition:
winuser.h:3224
_WNDCLASSEXW::style
UINT style
Definition:
winuser.h:3220
_WNDCLASSEXW::cbClsExtra
int cbClsExtra
Definition:
winuser.h:3222
_WNDCLASSEXW::hIcon
HICON hIcon
Definition:
winuser.h:3225
PWSTR
uint16_t * PWSTR
Definition:
typedefs.h:56
GetModuleHandle
#define GetModuleHandle
Definition:
winbase.h:3852
CreateSolidBrush
HBRUSH WINAPI CreateSolidBrush(_In_ COLORREF)
GetClassInfoExW
BOOL WINAPI GetClassInfoExW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _Out_ LPWNDCLASSEXW)
RegisterClassExW
ATOM WINAPI RegisterClassExW(_In_ CONST WNDCLASSEXW *)
WNDCLASSEXW
struct _WNDCLASSEXW WNDCLASSEXW
modules
rostests
apitests
win32nt
ntuser
NtUserGetClassInfo.c
Generated on Tue Jan 21 2025 06:08:19 for ReactOS by
1.9.6