Fixing the argument type definition of Marshal.GetNativeVariantForObject method in EnumVariantObject#4168
Conversation
There was a problem hiding this comment.
Did you identify what causes the erorr? You are changing the signature of a ComImport IUnknown interface, and of private implementation methods, neither of which are relevant (or visible) to external users
- ComImport means the definition is external (you don't generate the definition)
- IUnknown means you are implementing the definition without "reflection" support that comes with IDispatch/Dual interfaces (i.e. COM will not be aware of how you implemented it)
I don't see any point in this changeset which could have an effect to external users of the interface. In particular since the official headers also use unsigned numbers there should never be any negative numbers appear anywhere.
If this fixes the problem I'm obviously missing something, and I'd like to know what :-)
|
I think I see it now, you are not actually touching the line which was broken, which is why I missed it. You are changing a lot more than necessary to fix the bug. The bug probably comes from The "minmal" (and IMHO correct) fix would be just adding a typecast to TLDR: while the PR fixes the bug I'd argue the signature changes to |
|
I had a brief chat with @JeremyKuhne, and whilst our definitions match those in oaidl.h (
👍 |
efb3a4e to
063108a
Compare
Codecov Report
@@ Coverage Diff @@
## master #4168 +/- ##
===================================================
- Coverage 98.12512% 98.11738% -0.00774%
===================================================
Files 497 497
Lines 258523 258523
Branches 4492 4492
===================================================
- Hits 253676 253656 -20
- Misses 4089 4105 +16
- Partials 758 762 +4
Flags with carried forward coverage won't be shown. Click here to find out more. |
|
@weltkante, you are cool as always! You are right. I really agree that changing Maybe @hughbe could say should we change |
I didn't see anything of that sort, but The signedness of the |
src/System.Windows.Forms/src/System/Windows/Forms/AccessibleObject.EnumVariantObject.cs
Outdated
Show resolved
Hide resolved
063108a to
3cc6ddc
Compare
for EnumVariantObject The fix allows users to see the correct accessibility tree of controls that don't support UIA using Inspect tool Fixes dotnet#4120 (LinkLabel accessiblity tree) Fixes dotnet#4121 (CheckedListBox accessiblity tree) The regression from 0c4d3cb
ad70d15
3cc6ddc to
ad70d15
Compare
|
Testers approved the fix ✔️ |
Fixes #4120 (
LinkLabelaccessiblity tree)Fixes #4121 (
CheckedListBoxaccessiblity tree)Fixes #4130 (MSAA
UpDowncontrols)Fixes #4172 (MSAA
CheckedListBox)Regression from 0c4d3cb
Proposed changes
currentChildfromuinttointbefore using in Marshal.GetNativeVariantForObjectCustomer Impact
Regression?
Risk
Screenshots
Before
CheckedListBoxdoesn't have internal items AccessibleObjects in the accessibility treeAfter
CheckedListBoxhas the correct accessibility tree with the internal itemsTest methodology
Accessibility testing
Test environment(s)
Microsoft Reviewers: Open in CodeFlow