Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
affd20d9
Commit
affd20d9
authored
Feb 25, 2009
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Fix some input tests on Win9x and NT4.
parent
b86552f5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
1 deletion
+23
-1
input.c
dlls/user32/tests/input.c
+23
-1
No files found.
dlls/user32/tests/input.c
View file @
affd20d9
...
@@ -755,6 +755,15 @@ static void compare_and_check(int id, BYTE *ks1, BYTE *ks2, struct sendinput_tes
...
@@ -755,6 +755,15 @@ static void compare_and_check(int id, BYTE *ks1, BYTE *ks2, struct sendinput_tes
"%2d (%x/%x): the msg 0x%04x was expected, but got msg 0x%04x instead
\n
"
,
"%2d (%x/%x): the msg 0x%04x was expected, but got msg 0x%04x instead
\n
"
,
id
,
test
->
wVk
,
test
->
dwFlags
,
expected
->
message
,
actual
->
message
);
id
,
test
->
wVk
,
test
->
dwFlags
,
expected
->
message
,
actual
->
message
);
}
}
/* NT4 doesn't send SYSKEYDOWN/UP to hooks, only KEYDOWN/UP */
else
if
((
expected
->
flags
&
hook
)
&&
(
expected
->
message
==
WM_SYSKEYDOWN
||
expected
->
message
==
WM_SYSKEYUP
)
&&
(
actual
->
message
==
expected
->
message
-
4
))
{
ok
((
expected
->
flags
&
hook
)
==
(
actual
->
flags
&
hook
),
"%2d (%x/%x): the msg 0x%04x should have been sent by a hook
\n
"
,
id
,
test
->
wVk
,
test
->
dwFlags
,
expected
->
message
);
}
else
else
ok
(
FALSE
,
ok
(
FALSE
,
"%2d (%x/%x): the msg 0x%04x was expected, but got msg 0x%04x instead
\n
"
,
"%2d (%x/%x): the msg 0x%04x was expected, but got msg 0x%04x instead
\n
"
,
...
@@ -888,6 +897,9 @@ static void test_Input_blackbox(void)
...
@@ -888,6 +897,9 @@ static void test_Input_blackbox(void)
if
(
!
ii
&&
sent_messages_cnt
<=
1
&&
!
memcmp
(
ks1
,
ks2
,
sizeof
(
ks1
)
))
if
(
!
ii
&&
sent_messages_cnt
<=
1
&&
!
memcmp
(
ks1
,
ks2
,
sizeof
(
ks1
)
))
{
{
win_skip
(
"window doesn't receive the queued input
\n
"
);
win_skip
(
"window doesn't receive the queued input
\n
"
);
/* release the key */
i
.
u
.
ki
.
dwFlags
|=
KEYEVENTF_KEYUP
;
pSendInput
(
1
,
(
INPUT
*
)
&
i
,
sizeof
(
TEST_INPUT
));
break
;
break
;
}
}
compare_and_check
(
ii
,
ks1
,
ks2
,
&
sendinput_test
[
ii
]);
compare_and_check
(
ii
,
ks1
,
ks2
,
&
sendinput_test
[
ii
]);
...
@@ -973,7 +985,11 @@ static void test_mouse_ll_hook(void)
...
@@ -973,7 +985,11 @@ static void test_mouse_ll_hook(void)
10
,
10
,
200
,
200
,
NULL
,
NULL
,
NULL
,
NULL
);
10
,
10
,
200
,
200
,
NULL
,
NULL
,
NULL
,
NULL
);
SetCursorPos
(
100
,
100
);
SetCursorPos
(
100
,
100
);
hook2
=
SetWindowsHookExA
(
WH_MOUSE_LL
,
hook_proc2
,
GetModuleHandleA
(
0
),
0
);
if
(
!
(
hook2
=
SetWindowsHookExA
(
WH_MOUSE_LL
,
hook_proc2
,
GetModuleHandleA
(
0
),
0
)))
{
win_skip
(
"cannot set MOUSE_LL hook
\n
"
);
goto
done
;
}
hook1
=
SetWindowsHookExA
(
WH_MOUSE_LL
,
hook_proc1
,
GetModuleHandleA
(
0
),
0
);
hook1
=
SetWindowsHookExA
(
WH_MOUSE_LL
,
hook_proc1
,
GetModuleHandleA
(
0
),
0
);
GetCursorPos
(
&
pt_old
);
GetCursorPos
(
&
pt_old
);
...
@@ -1030,6 +1046,7 @@ static void test_mouse_ll_hook(void)
...
@@ -1030,6 +1046,7 @@ static void test_mouse_ll_hook(void)
ok
(
pt
.
x
==
pt_new
.
x
&&
pt
.
y
==
pt_new
.
y
,
"Position changed: (%d,%d)
\n
"
,
pt
.
x
,
pt
.
y
);
ok
(
pt
.
x
==
pt_new
.
x
&&
pt
.
y
==
pt_new
.
y
,
"Position changed: (%d,%d)
\n
"
,
pt
.
x
,
pt
.
y
);
UnhookWindowsHookEx
(
hook2
);
UnhookWindowsHookEx
(
hook2
);
done:
DestroyWindow
(
hwnd
);
DestroyWindow
(
hwnd
);
SetCursorPos
(
pt_org
.
x
,
pt_org
.
y
);
SetCursorPos
(
pt_org
.
x
,
pt_org
.
y
);
}
}
...
@@ -1058,6 +1075,11 @@ static void test_GetMouseMovePointsEx(void)
...
@@ -1058,6 +1075,11 @@ static void test_GetMouseMovePointsEx(void)
*/
*/
SetLastError
(
MYERROR
);
SetLastError
(
MYERROR
);
retval
=
pGetMouseMovePointsEx
(
0
,
&
in
,
out
,
BUFLIM
,
GMMP_USE_DISPLAY_POINTS
);
retval
=
pGetMouseMovePointsEx
(
0
,
&
in
,
out
,
BUFLIM
,
GMMP_USE_DISPLAY_POINTS
);
if
(
retval
==
ERROR_INVALID_PARAMETER
)
{
win_skip
(
"GetMouseMovePointsEx broken on WinME
\n
"
);
return
;
}
ok
(
retval
==
-
1
,
"expected GetMouseMovePointsEx to fail, got %d
\n
"
,
retval
);
ok
(
retval
==
-
1
,
"expected GetMouseMovePointsEx to fail, got %d
\n
"
,
retval
);
ok
(
GetLastError
()
==
ERROR_INVALID_PARAMETER
||
GetLastError
()
==
MYERROR
,
ok
(
GetLastError
()
==
ERROR_INVALID_PARAMETER
||
GetLastError
()
==
MYERROR
,
"expected error ERROR_INVALID_PARAMETER, got %u
\n
"
,
GetLastError
());
"expected error ERROR_INVALID_PARAMETER, got %u
\n
"
,
GetLastError
());
...
...
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