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
43b0dce2
Commit
43b0dce2
authored
Feb 09, 2017
by
Fabian Maurer
Committed by
Alexandre Julliard
Feb 16, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Add tests for disabled buttons receiving WM_LBUTTONUP.
Signed-off-by:
Fabian Maurer
<
dark.shadow4@web.de
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
83cde069
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
35 additions
and
0 deletions
+35
-0
msg.c
dlls/user32/tests/msg.c
+35
-0
No files found.
dlls/user32/tests/msg.c
View file @
43b0dce2
...
...
@@ -6060,6 +6060,23 @@ static const struct message WmClearStateButtonSeq[] =
{
WM_APP
,
sent
|
wparam
|
lparam
,
0
,
0
},
{
0
}
};
static
const
struct
message
WmDisableButtonSeq
[]
=
{
{
WM_LBUTTONDOWN
,
sent
},
{
BM_SETSTATE
,
sent
|
defwinproc
},
{
WM_CTLCOLORSTATIC
,
sent
|
defwinproc
|
optional
},
{
WM_CTLCOLORBTN
,
sent
|
optional
},
{
WM_LBUTTONUP
,
sent
},
{
BM_SETSTATE
,
sent
|
defwinproc
},
{
WM_CTLCOLORBTN
,
sent
|
defwinproc
|
optional
},
{
WM_CTLCOLORSTATIC
,
sent
|
defwinproc
|
optional
},
{
BM_SETCHECK
,
sent
|
defwinproc
|
optional
},
{
WM_CTLCOLORBTN
,
sent
|
optional
},
{
WM_CTLCOLORSTATIC
,
sent
|
defwinproc
|
optional
},
{
WM_CAPTURECHANGED
,
sent
|
defwinproc
},
{
WM_COMMAND
,
sent
},
{
0
}
};
static
const
struct
message
WmClearStateOwnerdrawSeq
[]
=
{
{
BM_SETSTATE
,
sent
},
...
...
@@ -6448,6 +6465,24 @@ static void test_button_messages(void)
DeleteObject
(
hfont2
);
DestroyWindow
(
parent
);
/* Test if WM_LBUTTONDOWN and WM_LBUTTONUP to a disabled button leads to a WM_COMMAND for the parent */
parent
=
CreateWindowExA
(
0
,
"TestWindowClass"
,
"Test overlapped"
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
100
,
100
,
200
,
200
,
0
,
0
,
0
,
NULL
);
ok
(
hwnd
!=
0
,
"Failed to create overlapped window
\n
"
);
hwnd
=
CreateWindowExA
(
0
,
"my_button_class"
,
"test"
,
BS_DEFPUSHBUTTON
|
WS_VISIBLE
|
WS_CHILD
,
0
,
0
,
50
,
14
,
parent
,
0
,
0
,
NULL
);
EnableWindow
(
hwnd
,
FALSE
);
flush_sequence
();
SendMessageA
(
hwnd
,
WM_LBUTTONDOWN
,
MK_LBUTTON
,
0
);
SendMessageA
(
hwnd
,
WM_LBUTTONUP
,
0
,
0
);
ok_sequence
(
WmDisableButtonSeq
,
"Mouseclick on a disabled button"
,
FALSE
);
DestroyWindow
(
hwnd
);
DestroyWindow
(
parent
);
}
/****************** static message test *************************/
...
...
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