Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lucas pereira de Freitas
wine
Commits
c52d7acf
Commit
c52d7acf
authored
12 years ago
by
Daniel Jelinski
Committed by
Alexandre Julliard
12 years ago
Browse files
Options
Downloads
Patches
Plain Diff
comctl32/tests: Added test for treeview expand notifications on keyboard events.
parent
38a76ecb
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dlls/comctl32/tests/treeview.c
+39
-0
39 additions, 0 deletions
dlls/comctl32/tests/treeview.c
with
39 additions
and
0 deletions
dlls/comctl32/tests/treeview.c
+
39
−
0
View file @
c52d7acf
...
...
@@ -204,6 +204,20 @@ static const struct message parent_expand_seq[] = {
{
0
}
};
static
const
struct
message
parent_expand_kb_seq
[]
=
{
{
WM_NOTIFY
,
sent
|
id
|
optional
,
0
,
0
,
TVN_KEYDOWN
},
{
WM_NOTIFY
,
sent
|
id
,
0
,
0
,
TVN_ITEMEXPANDINGA
},
{
WM_NOTIFY
,
sent
|
id
,
0
,
0
,
TVN_ITEMEXPANDEDA
},
{
WM_CHANGEUISTATE
,
sent
|
optional
},
{
0
}
};
static
const
struct
message
parent_expand_empty_kb_seq
[]
=
{
{
WM_NOTIFY
,
sent
|
id
|
optional
,
0
,
0
,
TVN_KEYDOWN
},
{
WM_CHANGEUISTATE
,
sent
|
optional
},
{
0
}
};
static
const
struct
message
parent_singleexpand_seq
[]
=
{
{
WM_NOTIFY
,
sent
|
id
,
0
,
0
,
TVN_SELCHANGINGA
},
{
WM_NOTIFY
,
sent
|
id
,
0
,
0
,
TVN_SELCHANGEDA
},
...
...
@@ -1423,6 +1437,31 @@ static void test_expandnotify(void)
ok_sequence
(
sequences
,
PARENT_SEQ_INDEX
,
empty_seq
,
"toggle node (collapse)"
,
FALSE
);
DestroyWindow
(
hTree
);
/* some keyboard events are also translated to expand */
hTree
=
create_treeview_control
(
0
);
fill_tree
(
hTree
);
/* preselect root node here */
ret
=
SendMessageA
(
hTree
,
TVM_SELECTITEM
,
TVGN_CARET
,
(
LPARAM
)
hRoot
);
expect
(
TRUE
,
ret
);
flush_sequences
(
sequences
,
NUM_MSG_SEQUENCES
);
ret
=
SendMessageA
(
hTree
,
WM_KEYDOWN
,
VK_ADD
,
0
);
expect
(
FALSE
,
ret
);
ok_sequence
(
sequences
,
PARENT_SEQ_INDEX
,
parent_expand_kb_seq
,
"expand node"
,
FALSE
);
/* go to child */
ret
=
SendMessageA
(
hTree
,
WM_KEYDOWN
,
VK_RIGHT
,
0
);
expect
(
FALSE
,
ret
);
/* try to expand child that doesn't have children itself */
flush_sequences
(
sequences
,
NUM_MSG_SEQUENCES
);
ret
=
SendMessageA
(
hTree
,
WM_KEYDOWN
,
VK_ADD
,
0
);
expect
(
FALSE
,
ret
);
ok_sequence
(
sequences
,
PARENT_SEQ_INDEX
,
parent_expand_empty_kb_seq
,
"expand node with no children"
,
TRUE
);
DestroyWindow
(
hTree
);
}
static
void
test_expandedimage
(
void
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment