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
6f3bd0bc
Commit
6f3bd0bc
authored
Mar 09, 2023
by
Connor McAdams
Committed by
Alexandre Julliard
Mar 20, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
uiautomationcore: Implement IUIAutomationTreeWalker::GetParentElement{BuildCache}.
Signed-off-by:
Connor McAdams
<
cmcadams@codeweavers.com
>
parent
b9d10cee
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
4 deletions
+41
-4
uiautomation.c
dlls/uiautomationcore/tests/uiautomation.c
+33
-0
uia_com_client.c
dlls/uiautomationcore/uia_com_client.c
+8
-4
No files found.
dlls/uiautomationcore/tests/uiautomation.c
View file @
6f3bd0bc
...
...
@@ -11753,6 +11753,19 @@ static const struct prov_method_sequence treewalker_seq8[] = {
{
0
}
};
static
const
struct
prov_method_sequence
treewalker_seq9
[]
=
{
{
&
Provider_child2
,
FRAG_NAVIGATE
},
/* NavigateDirection_Parent */
NODE_CREATE_SEQ
(
&
Provider
),
{
0
}
};
static
const
struct
prov_method_sequence
treewalker_seq10
[]
=
{
{
&
Provider_child2
,
FRAG_NAVIGATE
},
/* NavigateDirection_Parent */
NODE_CREATE_SEQ
(
&
Provider
),
{
&
Provider
,
FRAG_GET_RUNTIME_ID
},
{
0
}
};
static
void
test_CUIAutomation_TreeWalker_ifaces
(
IUIAutomation
*
uia_iface
)
{
HWND
hwnd
=
create_test_hwnd
(
"test_CUIAutomation_TreeWalker_ifaces class"
);
...
...
@@ -11879,6 +11892,26 @@ static void test_CUIAutomation_TreeWalker_ifaces(IUIAutomation *uia_iface)
IUIAutomationElement_Release
(
element3
);
ok
(
Provider_child
.
ref
==
1
,
"Unexpected refcnt %ld
\n
"
,
Provider_child
.
ref
);
/* NavigateDirection_Parent. */
element3
=
NULL
;
Provider
.
hwnd
=
NULL
;
hr
=
IUIAutomationTreeWalker_GetParentElement
(
walker
,
element2
,
&
element3
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
ok
(
Provider
.
ref
==
3
,
"Unexpected refcnt %ld
\n
"
,
Provider
.
ref
);
ok
(
!!
element3
,
"element3 == NULL
\n
"
);
ok_method_sequence
(
treewalker_seq9
,
"treewalker_seq9"
);
IUIAutomationElement_Release
(
element3
);
ok
(
Provider
.
ref
==
2
,
"Unexpected refcnt %ld
\n
"
,
Provider
.
ref
);
element3
=
NULL
;
hr
=
IUIAutomationTreeWalker_GetParentElementBuildCache
(
walker
,
element2
,
cache_req
,
&
element3
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
ok
(
Provider
.
ref
==
3
,
"Unexpected refcnt %ld
\n
"
,
Provider
.
ref
);
ok
(
!!
element3
,
"element3 == NULL
\n
"
);
ok_method_sequence
(
treewalker_seq10
,
"treewalker_seq10"
);
IUIAutomationElement_Release
(
element3
);
ok
(
Provider
.
ref
==
2
,
"Unexpected refcnt %ld
\n
"
,
Provider
.
ref
);
IUIAutomationElement_Release
(
element2
);
ok
(
Provider_child2
.
ref
==
1
,
"Unexpected refcnt %ld
\n
"
,
Provider_child2
.
ref
);
...
...
dlls/uiautomationcore/uia_com_client.c
View file @
6f3bd0bc
...
...
@@ -2499,8 +2499,11 @@ static ULONG WINAPI uia_tree_walker_Release(IUIAutomationTreeWalker *iface)
static
HRESULT
WINAPI
uia_tree_walker_GetParentElement
(
IUIAutomationTreeWalker
*
iface
,
IUIAutomationElement
*
elem
,
IUIAutomationElement
**
parent
)
{
FIXME
(
"%p, %p, %p: stub
\n
"
,
iface
,
elem
,
parent
);
return
E_NOTIMPL
;
struct
uia_tree_walker
*
tree_walker
=
impl_from_IUIAutomationTreeWalker
(
iface
);
TRACE
(
"%p, %p, %p
\n
"
,
iface
,
elem
,
parent
);
return
IUIAutomationTreeWalker_GetParentElementBuildCache
(
iface
,
elem
,
tree_walker
->
default_cache_req
,
parent
);
}
static
HRESULT
WINAPI
uia_tree_walker_GetFirstChildElement
(
IUIAutomationTreeWalker
*
iface
,
IUIAutomationElement
*
elem
,
...
...
@@ -2587,8 +2590,9 @@ static HRESULT uia_tree_walker_navigate(IUIAutomationTreeWalker *walker, IUIAuto
static
HRESULT
WINAPI
uia_tree_walker_GetParentElementBuildCache
(
IUIAutomationTreeWalker
*
iface
,
IUIAutomationElement
*
elem
,
IUIAutomationCacheRequest
*
cache_req
,
IUIAutomationElement
**
parent
)
{
FIXME
(
"%p, %p, %p, %p: stub
\n
"
,
iface
,
elem
,
cache_req
,
parent
);
return
E_NOTIMPL
;
TRACE
(
"%p, %p, %p, %p
\n
"
,
iface
,
elem
,
cache_req
,
parent
);
return
uia_tree_walker_navigate
(
iface
,
cache_req
,
elem
,
NavigateDirection_Parent
,
parent
);
}
static
HRESULT
WINAPI
uia_tree_walker_GetFirstChildElementBuildCache
(
IUIAutomationTreeWalker
*
iface
,
...
...
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