From 3da1c279dca3ba857f9f8c12d089fb0205334ba9 Mon Sep 17 00:00:00 2001 From: ritoban23 Date: Wed, 3 Dec 2025 08:17:42 +0530 Subject: [PATCH 1/2] [Fabric] Fix UIA_LiveSettingPropertyId to use VT_I4 datatype instead of VT_BSTR Fixes #15050 Use GetLiveSetting() conversion function to properly convert accessibilityLiveRegion string values to long (VT_I4) datatype as required by UIA_LiveSettingPropertyId. --- .../react-native-windows-fix-uia-livesetting-datatype.json | 7 +++++++ .../Fabric/Composition/CompositionViewComponentView.cpp | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) create mode 100644 change/react-native-windows-fix-uia-livesetting-datatype.json diff --git a/change/react-native-windows-fix-uia-livesetting-datatype.json b/change/react-native-windows-fix-uia-livesetting-datatype.json new file mode 100644 index 00000000000..761b6dbffd6 --- /dev/null +++ b/change/react-native-windows-fix-uia-livesetting-datatype.json @@ -0,0 +1,7 @@ +{ + "type": "prerelease", + "comment": "[Fabric] Fix UIA_LiveSettingPropertyId to use VT_I4 datatype instead of VT_BSTR by using GetLiveSetting() conversion function", + "packageName": "react-native-windows", + "email": "ankudutt101@gmail.com", + "dependentChangeType": "patch" +} diff --git a/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp b/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp index 03f4bb0cb2c..8bf6ec26d2e 100644 --- a/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp +++ b/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp @@ -799,8 +799,8 @@ void ComponentView::updateAccessibilityProps( winrt::Microsoft::ReactNative::implementation::UpdateUiaProperty( EnsureUiaProvider(), UIA_LiveSettingPropertyId, - oldViewProps.accessibilityLiveRegion, - newViewProps.accessibilityLiveRegion); + GetLiveSetting(oldViewProps.accessibilityLiveRegion), + GetLiveSetting(newViewProps.accessibilityLiveRegion)); winrt::Microsoft::ReactNative::implementation::UpdateUiaProperty( EnsureUiaProvider(), UIA_LevelPropertyId, oldViewProps.accessibilityLevel, newViewProps.accessibilityLevel); From 5d9ed501c0cf001d551fd2ed8669ba8575f0a8bc Mon Sep 17 00:00:00 2001 From: vineethkuttan <66076509+vineethkuttan@users.noreply.github.com> Date: Fri, 12 Dec 2025 11:25:32 +0530 Subject: [PATCH 2/2] call function with namespace --- ...-native-windows-5bfa5aa2-4028-4dd5-bb13-031b42470bd2.json} | 2 +- .../Fabric/Composition/CompositionViewComponentView.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) rename change/{react-native-windows-fix-uia-livesetting-datatype.json => react-native-windows-5bfa5aa2-4028-4dd5-bb13-031b42470bd2.json} (72%) diff --git a/change/react-native-windows-fix-uia-livesetting-datatype.json b/change/react-native-windows-5bfa5aa2-4028-4dd5-bb13-031b42470bd2.json similarity index 72% rename from change/react-native-windows-fix-uia-livesetting-datatype.json rename to change/react-native-windows-5bfa5aa2-4028-4dd5-bb13-031b42470bd2.json index 761b6dbffd6..c59a5341ba5 100644 --- a/change/react-native-windows-fix-uia-livesetting-datatype.json +++ b/change/react-native-windows-5bfa5aa2-4028-4dd5-bb13-031b42470bd2.json @@ -1,6 +1,6 @@ { "type": "prerelease", - "comment": "[Fabric] Fix UIA_LiveSettingPropertyId to use VT_I4 datatype instead of VT_BSTR by using GetLiveSetting() conversion function", + "comment": "[Fabric] Fix UIA_LiveSettingPropertyId to use VT_I4 datatype instead of VT_BSTR", "packageName": "react-native-windows", "email": "ankudutt101@gmail.com", "dependentChangeType": "patch" diff --git a/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp b/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp index 8bf6ec26d2e..00f5ea73b21 100644 --- a/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp +++ b/vnext/Microsoft.ReactNative/Fabric/Composition/CompositionViewComponentView.cpp @@ -799,8 +799,8 @@ void ComponentView::updateAccessibilityProps( winrt::Microsoft::ReactNative::implementation::UpdateUiaProperty( EnsureUiaProvider(), UIA_LiveSettingPropertyId, - GetLiveSetting(oldViewProps.accessibilityLiveRegion), - GetLiveSetting(newViewProps.accessibilityLiveRegion)); + winrt::Microsoft::ReactNative::implementation::GetLiveSetting(oldViewProps.accessibilityLiveRegion), + winrt::Microsoft::ReactNative::implementation::GetLiveSetting(newViewProps.accessibilityLiveRegion)); winrt::Microsoft::ReactNative::implementation::UpdateUiaProperty( EnsureUiaProvider(), UIA_LevelPropertyId, oldViewProps.accessibilityLevel, newViewProps.accessibilityLevel);