1
0
Fork 0
mirror of synced 2025-03-07 03:53:26 +01:00

uiautomationcore: Add support for UIAutomationType_Double properties.

Signed-off-by: Connor McAdams <cmcadams@codeweavers.com>
This commit is contained in:
Connor McAdams 2022-06-20 16:05:12 -04:00 committed by Alexandre Julliard
parent 9639d0d6db
commit d83c019102
3 changed files with 26 additions and 11 deletions

View file

@ -4237,19 +4237,13 @@ static void check_uia_prop_val(PROPERTYID prop_id, enum UIAutomationType type, V
break;
case UIAutomationType_Double:
todo_wine ok(V_VT(v) == VT_R8, "Unexpected VT %d\n", V_VT(v));
if (V_VT(v) != VT_R8)
break;
ok(V_VT(v) == VT_R8, "Unexpected VT %d\n", V_VT(v));
ok(V_R8(v) == uia_r8_prop_val, "Unexpected R8 %lf\n", V_R8(v));
ok_method_sequence(get_prop_seq, NULL);
break;
case UIAutomationType_DoubleArray:
todo_wine ok(V_VT(v) == (VT_ARRAY | VT_R8), "Unexpected VT %d\n", V_VT(v));
if (V_VT(v) != (VT_ARRAY | VT_R8))
break;
ok(V_VT(v) == (VT_ARRAY | VT_R8), "Unexpected VT %d\n", V_VT(v));
for (idx = 0; idx < ARRAY_SIZE(uia_r8_arr_prop_val); idx++)
{
double val;

View file

@ -369,6 +369,24 @@ static HRESULT WINAPI uia_provider_get_prop_val(IWineUiaProvider *iface,
*ret_val = v;
break;
case UIAutomationType_Double:
if (V_VT(&v) != VT_R8)
{
WARN("Invalid vt %d for UIAutomationType_Double\n", V_VT(&v));
goto exit;
}
*ret_val = v;
break;
case UIAutomationType_DoubleArray:
if (V_VT(&v) != (VT_R8 | VT_ARRAY))
{
WARN("Invalid vt %d for UIAutomationType_DoubleArray\n", V_VT(&v));
goto exit;
}
*ret_val = v;
break;
case UIAutomationType_Element:
{
IRawElementProviderSimple *elprov;

View file

@ -48,7 +48,8 @@ static const struct uia_prop_info default_uia_properties[] = {
{ &Transform2_ZoomLevel_Property_GUID, UIA_Transform2ZoomLevelPropertyId, },
{ &Name_Property_GUID, UIA_NamePropertyId, },
{ &GridItem_RowSpan_Property_GUID, UIA_GridItemRowSpanPropertyId, },
{ &Size_Property_GUID, UIA_SizePropertyId, },
{ &Size_Property_GUID, UIA_SizePropertyId,
UIAutomationType_DoubleArray, },
{ &IsTextPattern2Available_Property_GUID, UIA_IsTextPattern2AvailablePropertyId, },
{ &Styles_FillPatternStyle_Property_GUID, UIA_StylesFillPatternStylePropertyId, },
{ &FlowsTo_Property_GUID, UIA_FlowsToPropertyId,
@ -143,7 +144,8 @@ static const struct uia_prop_info default_uia_properties[] = {
{ &Drag_DropEffect_Property_GUID, UIA_DragDropEffectPropertyId, },
{ &MultipleView_CurrentView_Property_GUID, UIA_MultipleViewCurrentViewPropertyId, },
{ &Styles_FillColor_Property_GUID, UIA_StylesFillColorPropertyId, },
{ &Rotation_Property_GUID, UIA_RotationPropertyId, },
{ &Rotation_Property_GUID, UIA_RotationPropertyId,
UIAutomationType_Double, },
{ &SpreadsheetItem_Formula_Property_GUID, UIA_SpreadsheetItemFormulaPropertyId, },
{ &IsEnabled_Property_GUID, UIA_IsEnabledPropertyId, },
{ &LocalizedLandmarkType_Property_GUID, UIA_LocalizedLandmarkTypePropertyId, },
@ -198,7 +200,8 @@ static const struct uia_prop_info default_uia_properties[] = {
{ &Table_RowOrColumnMajor_Property_GUID, UIA_TableRowOrColumnMajorPropertyId, },
{ &IsDockPatternAvailable_Property_GUID, UIA_IsDockPatternAvailablePropertyId, },
{ &IsSynchronizedInputPatternAvailable_Property_GUID,UIA_IsSynchronizedInputPatternAvailablePropertyId, },
{ &OutlineThickness_Property_GUID, UIA_OutlineThicknessPropertyId, },
{ &OutlineThickness_Property_GUID, UIA_OutlineThicknessPropertyId,
UIAutomationType_DoubleArray, },
{ &IsLegacyIAccessiblePatternAvailable_Property_GUID,UIA_IsLegacyIAccessiblePatternAvailablePropertyId, },
{ &AnnotationObjects_Property_GUID, UIA_AnnotationObjectsPropertyId,
UIAutomationType_ElementArray, },