Module: wine Branch: master Commit: cd6891962b070708228f1c32bf3480c3ae65a9ca URL: https://gitlab.winehq.org/wine/wine/-/commit/cd6891962b070708228f1c32bf3480c...
Author: Connor McAdams cmcadams@codeweavers.com Date: Thu Jan 12 11:54:28 2023 -0500
uiautomationcore: Implement IUIAutomation reserved value retrieval methods.
Signed-off-by: Connor McAdams cmcadams@codeweavers.com
---
dlls/uiautomationcore/tests/uiautomation.c | 20 ++++++++++++++++++++ dlls/uiautomationcore/uia_com_client.c | 10 ++++++---- 2 files changed, 26 insertions(+), 4 deletions(-)
diff --git a/dlls/uiautomationcore/tests/uiautomation.c b/dlls/uiautomationcore/tests/uiautomation.c index 1752682a5a7..c2982174463 100644 --- a/dlls/uiautomationcore/tests/uiautomation.c +++ b/dlls/uiautomationcore/tests/uiautomation.c @@ -10109,6 +10109,7 @@ static const struct uia_com_classes com_classes[] = { static void test_CUIAutomation(void) { IUIAutomation *uia_iface; + IUnknown *unk1, *unk2; BOOL has_cui8 = TRUE; HRESULT hr; int i; @@ -10152,6 +10153,25 @@ static void test_CUIAutomation(void) ok(hr == S_OK, "Failed to create IUIAutomation interface, hr %#lx\n", hr); ok(!!uia_iface, "uia_iface == NULL\n");
+ /* Reserved value retrieval methods. */ + hr = UiaGetReservedNotSupportedValue(&unk1); + ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); + + hr = IUIAutomation_get_ReservedNotSupportedValue(uia_iface, &unk2); + ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); + ok(unk1 == unk2, "unk1 != unk2\n"); + IUnknown_Release(unk1); + IUnknown_Release(unk2); + + hr = UiaGetReservedMixedAttributeValue(&unk1); + ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); + + hr = IUIAutomation_get_ReservedMixedAttributeValue(uia_iface, &unk2); + ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); + ok(unk1 == unk2, "unk1 != unk2\n"); + IUnknown_Release(unk1); + IUnknown_Release(unk2); + test_CUIAutomation_value_conversion(uia_iface); test_ElementFromHandle(uia_iface, has_cui8); test_Element_GetPropertyValue(uia_iface); diff --git a/dlls/uiautomationcore/uia_com_client.c b/dlls/uiautomationcore/uia_com_client.c index de01517948a..33a1967e489 100644 --- a/dlls/uiautomationcore/uia_com_client.c +++ b/dlls/uiautomationcore/uia_com_client.c @@ -1509,14 +1509,16 @@ static HRESULT WINAPI uia_iface_CheckNotSupported(IUIAutomation6 *iface, VARIANT
static HRESULT WINAPI uia_iface_get_ReservedNotSupportedValue(IUIAutomation6 *iface, IUnknown **out_unk) { - FIXME("%p, %p: stub\n", iface, out_unk); - return E_NOTIMPL; + TRACE("%p, %p\n", iface, out_unk); + + return UiaGetReservedNotSupportedValue(out_unk); }
static HRESULT WINAPI uia_iface_get_ReservedMixedAttributeValue(IUIAutomation6 *iface, IUnknown **out_unk) { - FIXME("%p, %p: stub\n", iface, out_unk); - return E_NOTIMPL; + TRACE("%p, %p\n", iface, out_unk); + + return UiaGetReservedMixedAttributeValue(out_unk); }
static HRESULT WINAPI uia_iface_ElementFromIAccessible(IUIAutomation6 *iface, IAccessible *acc, int cid,