From c557ec99ccc9f8dccb5c7f4bff6df408c5e7c1be Mon Sep 17 00:00:00 2001 From: Rishabh Chauhan Date: Thu, 6 Jun 2024 15:53:50 +0530 Subject: [PATCH] Adding Subitem value to hitTest --- .../MS/Internal/AutomationProxies/WindowsListView.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationClientSideProviders/MS/Internal/AutomationProxies/WindowsListView.cs b/src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationClientSideProviders/MS/Internal/AutomationProxies/WindowsListView.cs index 06c6a054390..b22f30132a0 100644 --- a/src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationClientSideProviders/MS/Internal/AutomationProxies/WindowsListView.cs +++ b/src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationClientSideProviders/MS/Internal/AutomationProxies/WindowsListView.cs @@ -1426,6 +1426,7 @@ static internal NativeMethods.LVHITTESTINFO_INTERNAL SubitemHitTest (IntPtr hwnd result = XSendMessage.XSendGetIndex(hwnd, NativeMethods.LVM_SUBITEMHITTEST, IntPtr.Zero, new IntPtr(&hitTestNative), Marshal.SizeOf(hitTestNative.GetType())); hitTest.flags = hitTestNative.flags; hitTest.iItem = hitTestNative.iItem; + hitTest.iSubItem = hitTestNative.iSubItem; hitTest.iGroup = hitTestNative.iGroup; } else @@ -1434,6 +1435,7 @@ static internal NativeMethods.LVHITTESTINFO_INTERNAL SubitemHitTest (IntPtr hwnd result = XSendMessage.XSendGetIndex(hwnd, NativeMethods.LVM_SUBITEMHITTEST, IntPtr.Zero, new IntPtr(&hitTestNative), Marshal.SizeOf(hitTestNative.GetType())); hitTest.flags = hitTestNative.flags; hitTest.iItem = hitTestNative.iItem; + hitTest.iSubItem = hitTestNative.iSubItem; } } }