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
5ccc6380
Commit
5ccc6380
authored
Jan 19, 2007
by
Kirill K. Smirnov
Committed by
Alexandre Julliard
Feb 13, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Add tests for WM_SETICON.
parent
828cb4f4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
53 additions
and
0 deletions
+53
-0
msg.c
dlls/user32/tests/msg.c
+53
-0
No files found.
dlls/user32/tests/msg.c
View file @
5ccc6380
...
...
@@ -3670,6 +3670,21 @@ static void test_sys_menu(void)
DestroyWindow
(
hwnd
);
}
/* For shown WS_OVERLAPPEDWINDOW */
static
const
struct
message
WmSetIcon_1
[]
=
{
{
WM_SETICON
,
sent
},
{
0x00AE
,
sent
|
defwinproc
|
optional
},
/* XP */
{
WM_GETTEXT
,
sent
|
defwinproc
|
optional
},
{
WM_GETTEXT
,
sent
|
defwinproc
|
optional
},
/* XP sends a duplicate */
{
0
}
};
/* For WS_POPUP and hidden WS_OVERLAPPEDWINDOW */
static
const
struct
message
WmSetIcon_2
[]
=
{
{
WM_SETICON
,
sent
},
{
0
}
};
/* test if we receive the right sequence of messages */
static
void
test_messages
(
void
)
{
...
...
@@ -3996,6 +4011,44 @@ static void test_messages(void)
DestroyWindow
(
hchild
);
DestroyWindow
(
hparent
);
flush_sequence
();
/* Message sequences for WM_SETICON */
trace
(
"testing WM_SETICON
\n
"
);
hwnd
=
CreateWindowExA
(
0
,
"TestWindowClass"
,
NULL
,
WS_OVERLAPPEDWINDOW
,
CW_USEDEFAULT
,
CW_USEDEFAULT
,
300
,
300
,
0
,
NULL
,
NULL
,
0
);
ShowWindow
(
hwnd
,
SW_SHOW
);
UpdateWindow
(
hwnd
);
while
(
PeekMessage
(
&
msg
,
0
,
0
,
0
,
PM_REMOVE
))
DispatchMessage
(
&
msg
);
flush_sequence
();
SendMessage
(
hwnd
,
WM_SETICON
,
ICON_SMALL
,
(
LPARAM
)
LoadIcon
(
0
,
IDI_APPLICATION
));
ok_sequence
(
WmSetIcon_1
,
"WM_SETICON for shown window with caption"
,
FALSE
);
ShowWindow
(
hwnd
,
SW_HIDE
);
while
(
PeekMessage
(
&
msg
,
0
,
0
,
0
,
PM_REMOVE
))
DispatchMessage
(
&
msg
);
flush_sequence
();
SendMessage
(
hwnd
,
WM_SETICON
,
ICON_SMALL
,
(
LPARAM
)
LoadIcon
(
0
,
IDI_APPLICATION
));
ok_sequence
(
WmSetIcon_2
,
"WM_SETICON for hidden window with caption"
,
FALSE
);
DestroyWindow
(
hwnd
);
flush_sequence
();
hwnd
=
CreateWindowExA
(
0
,
"TestPopupClass"
,
NULL
,
WS_POPUP
,
CW_USEDEFAULT
,
CW_USEDEFAULT
,
300
,
300
,
0
,
NULL
,
NULL
,
0
);
ShowWindow
(
hwnd
,
SW_SHOW
);
UpdateWindow
(
hwnd
);
while
(
PeekMessage
(
&
msg
,
0
,
0
,
0
,
PM_REMOVE
))
DispatchMessage
(
&
msg
);
flush_sequence
();
SendMessage
(
hwnd
,
WM_SETICON
,
ICON_SMALL
,
(
LPARAM
)
LoadIcon
(
0
,
IDI_APPLICATION
));
ok_sequence
(
WmSetIcon_2
,
"WM_SETICON for shown window without caption"
,
FALSE
);
ShowWindow
(
hwnd
,
SW_HIDE
);
while
(
PeekMessage
(
&
msg
,
0
,
0
,
0
,
PM_REMOVE
))
DispatchMessage
(
&
msg
);
flush_sequence
();
SendMessage
(
hwnd
,
WM_SETICON
,
ICON_SMALL
,
(
LPARAM
)
LoadIcon
(
0
,
IDI_APPLICATION
));
ok_sequence
(
WmSetIcon_2
,
"WM_SETICON for hidden window without caption"
,
FALSE
);
DestroyWindow
(
hwnd
);
flush_sequence
();
}
static
void
invisible_parent_tests
(
void
)
...
...
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