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
e79b1290
Commit
e79b1290
authored
Sep 14, 2022
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Fix a few more assumptions about window positions.
parent
f3eebcfa
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
10 deletions
+25
-10
input.c
dlls/user32/tests/input.c
+19
-8
msg.c
dlls/user32/tests/msg.c
+6
-2
No files found.
dlls/user32/tests/input.c
View file @
e79b1290
...
...
@@ -3466,7 +3466,8 @@ static void test_Input_mouse(void)
100
,
100
,
100
,
100
,
0
,
NULL
,
NULL
,
NULL
);
ok
(
button_win
!=
0
,
"CreateWindow failed
\n
"
);
pt
.
x
=
pt
.
y
=
150
;
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
button_win
,
&
pt
);
hwnd
=
WindowFromPoint
(
pt
);
if
(
hwnd
!=
button_win
)
{
...
...
@@ -3476,7 +3477,7 @@ static void test_Input_mouse(void)
}
/* simple button click test */
simulate_click
(
TRUE
,
150
,
150
);
simulate_click
(
TRUE
,
pt
.
x
,
pt
.
y
);
got_button_down
=
got_button_up
=
FALSE
;
while
(
wait_for_message
(
&
msg
))
{
...
...
@@ -3501,7 +3502,7 @@ static void test_Input_mouse(void)
ok
(
static_win
!=
0
,
"CreateWindow failed
\n
"
);
def_static_proc
=
(
void
*
)
SetWindowLongPtrA
(
static_win
,
GWLP_WNDPROC
,
(
LONG_PTR
)
static_hook_proc
);
simulate_click
(
FALSE
,
150
,
150
);
simulate_click
(
FALSE
,
pt
.
x
,
pt
.
y
);
hittest_no
=
0
;
got_button_down
=
got_button_up
=
FALSE
;
while
(
wait_for_message
(
&
msg
))
...
...
@@ -3531,7 +3532,9 @@ static void test_Input_mouse(void)
ok
(
static_win
!=
0
,
"CreateWindow failed
\n
"
);
def_static_proc
=
(
void
*
)
SetWindowLongPtrA
(
static_win
,
GWLP_WNDPROC
,
(
LONG_PTR
)
static_hook_proc
);
simulate_click
(
TRUE
,
150
,
150
);
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
static_win
,
&
pt
);
simulate_click
(
TRUE
,
pt
.
x
,
pt
.
y
);
hittest_no
=
0
;
got_button_down
=
got_button_up
=
FALSE
;
while
(
wait_for_message
(
&
msg
))
...
...
@@ -3565,7 +3568,9 @@ static void test_Input_mouse(void)
hittest_no
=
0
;
got_button_down
=
got_button_up
=
FALSE
;
WaitForSingleObject
(
thread_data
.
start_event
,
INFINITE
);
simulate_click
(
FALSE
,
150
,
150
);
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
thread_data
.
win
,
&
pt
);
simulate_click
(
FALSE
,
pt
.
x
,
pt
.
y
);
while
(
wait_for_message
(
&
msg
))
{
DispatchMessageA
(
&
msg
);
...
...
@@ -3593,7 +3598,9 @@ static void test_Input_mouse(void)
"AttachThreadInput failed
\n
"
);
while
(
wait_for_message
(
&
msg
))
DispatchMessageA
(
&
msg
);
SetWindowPos
(
thread_data
.
win
,
button_win
,
0
,
0
,
0
,
0
,
SWP_NOSIZE
|
SWP_NOMOVE
);
simulate_click
(
TRUE
,
150
,
150
);
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
thread_data
.
win
,
&
pt
);
simulate_click
(
TRUE
,
pt
.
x
,
pt
.
y
);
while
(
wait_for_message
(
&
msg
))
{
DispatchMessageA
(
&
msg
);
...
...
@@ -3615,7 +3622,9 @@ static void test_Input_mouse(void)
ok
(
hwnd
!=
0
,
"CreateWindow failed
\n
"
);
SetCapture
(
button_win
);
got_button_down
=
got_button_up
=
FALSE
;
simulate_click
(
FALSE
,
50
,
50
);
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
hwnd
,
&
pt
);
simulate_click
(
FALSE
,
pt
.
x
,
pt
.
y
);
while
(
wait_for_message
(
&
msg
))
{
DispatchMessageA
(
&
msg
);
...
...
@@ -3641,7 +3650,9 @@ static void test_Input_mouse(void)
0
,
0
,
100
,
100
,
button_win
,
NULL
,
NULL
,
NULL
);
ok
(
hwnd
!=
0
,
"CreateWindow failed
\n
"
);
got_button_down
=
got_button_up
=
FALSE
;
simulate_click
(
TRUE
,
150
,
150
);
pt
.
x
=
pt
.
y
=
50
;
ClientToScreen
(
hwnd
,
&
pt
);
simulate_click
(
TRUE
,
pt
.
x
,
pt
.
y
);
while
(
wait_for_message
(
&
msg
))
{
DispatchMessageA
(
&
msg
);
...
...
dlls/user32/tests/msg.c
View file @
e79b1290
...
...
@@ -17470,7 +17470,8 @@ static void test_keyflags(void)
MSG
msg
;
test_window
=
CreateWindowExA
(
0
,
"TestWindowClass"
,
NULL
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
100
,
100
,
200
,
200
,
0
,
0
,
0
,
NULL
);
0
,
0
,
GetSystemMetrics
(
SM_CXSCREEN
),
GetSystemMetrics
(
SM_CYSCREEN
),
0
,
0
,
0
,
NULL
);
flush_events
();
flush_sequence
();
...
...
@@ -17705,8 +17706,11 @@ static void test_hotkey(void)
"unexpected error %ld
\n
"
,
GetLastError
());
test_window
=
CreateWindowExA
(
0
,
"HotkeyWindowClass"
,
NULL
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
100
,
100
,
200
,
200
,
0
,
0
,
0
,
NULL
);
0
,
0
,
GetSystemMetrics
(
SM_CXSCREEN
),
GetSystemMetrics
(
SM_CYSCREEN
),
0
,
0
,
0
,
NULL
);
SetForegroundWindow
(
test_window
);
flush_events
();
flush_sequence
();
SetLastError
(
0xdeadbeef
);
...
...
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