Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
4bab221b
Commit
4bab221b
authored
Oct 27, 2022
by
Connor McAdams
Committed by
Alexandre Julliard
Nov 01, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
uiautomationcore: Add helper function for returning a new node from an IWineUiaProvider.
Signed-off-by:
Connor McAdams
<
cmcadams@codeweavers.com
>
parent
567f00c8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
17 deletions
+31
-17
uia_client.c
dlls/uiautomationcore/uia_client.c
+31
-17
No files found.
dlls/uiautomationcore/uia_client.c
View file @
4bab221b
...
...
@@ -694,6 +694,34 @@ static void get_variant_for_node(HUIANODE node, VARIANT *v)
#endif
}
static
HRESULT
get_variant_for_elprov_node
(
IRawElementProviderSimple
*
elprov
,
BOOL
out_nested
,
VARIANT
*
v
)
{
HUIANODE
node
;
HRESULT
hr
;
VariantInit
(
v
);
hr
=
create_uia_node_from_elprov
(
elprov
,
&
node
,
!
out_nested
);
IRawElementProviderSimple_Release
(
elprov
);
if
(
SUCCEEDED
(
hr
))
{
if
(
out_nested
)
{
LRESULT
lr
=
uia_lresult_from_node
(
node
);
if
(
!
lr
)
return
E_FAIL
;
V_VT
(
v
)
=
VT_I4
;
V_I4
(
v
)
=
lr
;
}
else
get_variant_for_node
(
node
,
v
);
}
return
S_OK
;
}
static
HRESULT
uia_provider_get_elem_prop_val
(
struct
uia_provider
*
prov
,
const
struct
uia_prop_info
*
prop_info
,
VARIANT
*
ret_val
)
{
...
...
@@ -764,7 +792,6 @@ static HRESULT uia_provider_get_elem_prop_val(struct uia_provider *prov,
case
UIAutomationType_Element
:
{
IRawElementProviderSimple
*
elprov
;
HUIANODE
node
;
if
(
V_VT
(
&
v
)
!=
VT_UNKNOWN
)
{
...
...
@@ -778,23 +805,10 @@ static HRESULT uia_provider_get_elem_prop_val(struct uia_provider *prov,
if
(
FAILED
(
hr
))
goto
exit
;
hr
=
create_uia_node_from_elprov
(
elprov
,
&
node
,
!
prov
->
return_nested_node
);
IRawElementProviderSimple_Release
(
elprov
);
if
(
SUCCEEDED
(
hr
))
{
if
(
prov
->
return_nested_node
)
{
LRESULT
lr
=
uia_lresult_from_node
(
node
);
if
(
!
lr
)
return
E_FAIL
;
hr
=
get_variant_for_elprov_node
(
elprov
,
prov
->
return_nested_node
,
ret_val
);
if
(
FAILED
(
hr
))
return
hr
;
V_VT
(
ret_val
)
=
VT_I4
;
V_I4
(
ret_val
)
=
lr
;
}
else
get_variant_for_node
(
node
,
ret_val
);
}
break
;
}
...
...
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