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
734600e2
Commit
734600e2
authored
Oct 14, 2007
by
Lei Zhang
Committed by
Alexandre Julliard
Oct 16, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Monthcal today link test.
parent
3accf13e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
71 additions
and
0 deletions
+71
-0
monthcal.c
dlls/comctl32/tests/monthcal.c
+71
-0
No files found.
dlls/comctl32/tests/monthcal.c
View file @
734600e2
...
...
@@ -221,6 +221,18 @@ static const struct message monthcal_hit_test_seq[] = {
{
0
}
};
static
const
struct
message
monthcal_todaylink_seq
[]
=
{
{
MCM_HITTEST
,
sent
|
wparam
,
0
},
{
MCM_SETTODAY
,
sent
|
wparam
,
0
},
{
WM_PAINT
,
sent
|
wparam
|
lparam
|
defwinproc
,
0
,
0
},
{
MCM_GETTODAY
,
sent
|
wparam
,
0
},
{
WM_LBUTTONDOWN
,
sent
|
wparam
|
lparam
,
MK_LBUTTON
,
MAKELONG
(
70
,
370
)},
{
WM_CAPTURECHANGED
,
sent
|
wparam
|
lparam
|
defwinproc
,
0
,
0
},
{
WM_PAINT
,
sent
|
wparam
|
lparam
|
defwinproc
,
0
,
0
},
{
MCM_GETCURSEL
,
sent
|
wparam
,
0
},
{
0
}
};
static
const
struct
message
monthcal_today_seq
[]
=
{
{
MCM_SETTODAY
,
sent
|
wparam
,
0
},
{
WM_PAINT
,
sent
|
wparam
|
lparam
|
defwinproc
,
0
,
0
},
...
...
@@ -896,6 +908,64 @@ static void test_monthcal_HitTest(HWND hwnd)
ok_sequence
(
sequences
,
MONTHCAL_SEQ_INDEX
,
monthcal_hit_test_seq
,
"monthcal hit test"
,
TRUE
);
}
static
void
test_monthcal_todaylink
(
HWND
hwnd
)
{
MCHITTESTINFO
mchit
;
SYSTEMTIME
st_test
,
st_new
;
BOOL
error
=
FALSE
;
int
res
;
memset
(
&
mchit
,
0
,
sizeof
(
MCHITTESTINFO
));
flush_sequences
(
sequences
,
NUM_MSG_SEQUENCES
);
/* (70, 370) is in active area - today link */
mchit
.
cbSize
=
sizeof
(
MCHITTESTINFO
);
mchit
.
pt
.
x
=
70
;
mchit
.
pt
.
y
=
370
;
res
=
SendMessage
(
hwnd
,
MCM_HITTEST
,
0
,
(
LPARAM
)
&
mchit
);
expect
(
70
,
mchit
.
pt
.
x
);
expect
(
370
,
mchit
.
pt
.
y
);
expect
(
mchit
.
uHit
,
res
);
todo_wine
{
expect
(
MCHT_TODAYLINK
,
res
);}
if
(
70
!=
mchit
.
pt
.
x
||
370
!=
mchit
.
pt
.
y
||
mchit
.
uHit
!=
res
||
MCHT_TODAYLINK
!=
res
)
error
=
TRUE
;
st_test
.
wDay
=
1
;
st_test
.
wMonth
=
1
;
st_test
.
wYear
=
2005
;
memset
(
&
st_new
,
0
,
sizeof
(
SYSTEMTIME
));
SendMessage
(
hwnd
,
MCM_SETTODAY
,
0
,
(
LPARAM
)
&
st_test
);
res
=
SendMessage
(
hwnd
,
MCM_GETTODAY
,
0
,
(
LPARAM
)
&
st_new
);
expect
(
1
,
res
);
expect
(
1
,
st_new
.
wDay
);
expect
(
1
,
st_new
.
wMonth
);
expect
(
2005
,
st_new
.
wYear
);
if
(
1
!=
res
||
1
!=
st_new
.
wDay
||
1
!=
st_new
.
wMonth
||
2005
!=
st_new
.
wYear
)
error
=
TRUE
;
if
(
error
)
{
skip
(
"cannot perform today link test
\n
"
);
return
;
}
res
=
SendMessage
(
hwnd
,
WM_LBUTTONDOWN
,
MK_LBUTTON
,
MAKELONG
(
70
,
370
));
expect
(
0
,
res
);
memset
(
&
st_new
,
0
,
sizeof
(
SYSTEMTIME
));
res
=
SendMessage
(
hwnd
,
MCM_GETCURSEL
,
0
,
(
LPARAM
)
&
st_new
);
expect
(
1
,
res
);
expect
(
1
,
st_new
.
wDay
);
expect
(
1
,
st_new
.
wMonth
);
expect
(
2005
,
st_new
.
wYear
);
ok_sequence
(
sequences
,
MONTHCAL_SEQ_INDEX
,
monthcal_todaylink_seq
,
"monthcal hit test"
,
TRUE
);
}
static
void
test_monthcal_today
(
HWND
hwnd
)
{
SYSTEMTIME
st_test
,
st_new
;
...
...
@@ -1063,6 +1133,7 @@ START_TEST(monthcal)
test_monthcal_scroll
(
hwnd
);
test_monthcal_monthrange
(
hwnd
);
test_monthcal_HitTest
(
hwnd
);
test_monthcal_todaylink
(
hwnd
);
flush_sequences
(
sequences
,
NUM_MSG_SEQUENCES
);
DestroyWindow
(
hwnd
);
...
...
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