Skip to content

Add ListViewGroup.Footer/FooterAlignment - #2654

Merged
RussKie merged 1 commit into
dotnet:masterfrom
hughbe:LVGROUP-footer
Mar 10, 2020
Merged

RussKie merged 1 commit into
dotnet:masterfrom
hughbe:LVGROUP-footer

Conversation

@hughbe

@hughbe hughbe commented Jan 7, 2020 •

Copy link
Copy Markdown
Contributor

Fixes #2653

Proposed changes

  • Add ListViewGroup.Footer
  • Add ListViewGroup.FooterAlignment

Customer Impact

  • New APIs to align with native comctl32 feature set

Regression?

  • No

Risk

  • Minimal

Screenshots

image

Test methodology

  • Unit tests
  • Integration tests
  • Manual tests

Accessibility testing

  • Inspect.exe and accessibility checker
Microsoft Reviewers: Open in CodeFlow

@hughbe
hughbe requested a review from a team as a code owner January 7, 2020 11:32
@RussKie RussKie added 🚫 * NO-MERGE * The PR is not ready for merge yet (see discussion for detailed reasons) api-ready-for-review (2) API is ready for formal API review; applied by the issue owner labels Jan 7, 2020
@hughbe
hughbe force-pushed the LVGROUP-footer branch 3 times, most recently from 582b4f4 to 171d8c2 Compare January 7, 2020 12:42
@codecov

codecov Bot commented Jan 7, 2020

Copy link
Copy Markdown

Codecov Report

Merging #2654 into master will increase coverage by 0.03078%.
The diff coverage is 94.04389%.

@@                Coverage Diff                 @@
##              master      #2654         +/-   ##
==================================================
+ Coverage   57.55801%   57.5888%   +0.03079%     
==================================================
  Files           1235       1235                 
  Lines         418126     418406        +280     
  Branches       38818      38830         +12     
==================================================
+ Hits          240665     240955        +290     
+ Misses        172081     172071         -10     
  Partials        5380       5380
Flag Coverage Δ
#Debug 57.5888% <94.04389%> (+0.03078%) ⬆️
#production 31.33439% <98.11321%> (+0.0247%) ⬆️
#test 98.91902% <93.23308%> (-0.0126%) ⬇️

@codecov

codecov Bot commented Jan 7, 2020 •

Copy link
Copy Markdown

Codecov Report

Merging #2654 into master will decrease coverage by 0.0058%.
The diff coverage is 94.04389%.

@@                Coverage Diff                 @@
##              master       #2654        +/-   ##
==================================================
- Coverage   58.88921%   58.88341%   -0.0058%     
==================================================
  Files           1242        1242                
  Lines         428542      428822       +280     
  Branches       38908       38920        +12     
==================================================
+ Hits          252365      252505       +140     
- Misses        170836      170982       +146     
+ Partials        5341        5335         -6
Flag Coverage Δ
#Debug 58.88341% <94.04389%> (-0.00581%) ⬇️
#production 31.77659% <98.11321%> (-0.03401%) ⬇️
#test 98.96307% <93.23308%> (-0.0119%) ⬇️

@RussKie RussKie removed the api-ready-for-review (2) API is ready for formal API review; applied by the issue owner label Jan 23, 2020
@hughbe
hughbe force-pushed the LVGROUP-footer branch 2 times, most recently from 8580e21 to c973061 Compare January 25, 2020 18:41
@hughbe

hughbe commented Mar 6, 2020

Copy link
Copy Markdown
Contributor Author

@RussKie is this now ready to review?

@RussKie RussKie left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

Please fill in the PR description as per the template.

@ghost ghost added the waiting-author-feedback The team requires more information from the author label Mar 9, 2020
@RussKie RussKie removed the 🚫 * NO-MERGE * The PR is not ready for merge yet (see discussion for detailed reasons) label Mar 9, 2020
@ghost ghost assigned hughbe Mar 9, 2020
@ghost ghost removed the waiting-author-feedback The team requires more information from the author label Mar 9, 2020
@hughbe

hughbe commented Mar 9, 2020

Copy link
Copy Markdown
Contributor Author

Please fill in the PR description as per the template.

Done, thanks

@RussKie
RussKie merged commit c3da51b into dotnet:master Mar 10, 2020
@ghost ghost added this to the 5.0 milestone Mar 10, 2020
@RussKie

RussKie commented Mar 10, 2020

Copy link
Copy Markdown
Contributor

Thank you

@hughbe
hughbe deleted the LVGROUP-footer branch March 10, 2020 07:58
}

[WinFormsFact]
public unsafe void ListViewGroup_Footer_GetGroupInfo_Success()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❗️ The tests are failing on CI agents, even though the build is reported as successful.
E.g. https://dev.azure.com/dnceng/public/_build/results?buildId=555069&view=artifacts&type=publishedArtifacts

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.Tests.ListViewGroupTests+<>c.<ListViewGroup_Footer_GetGroupInfo_Success>b__10_0()
   at System.RuntimeMethodHandle.InvokeMethod(System.Object, System.Object[], System.Signature, Boolean, Boolean)
   at System.Reflection.RuntimeMethodInfo.Invoke(System.Object, System.Reflection.BindingFlags, System.Reflection.Binder, System.Object[], System.Globalization.CultureInfo)
   at System.Reflection.MethodBase.Invoke(System.Object, System.Object[])
   at Microsoft.DotNet.RemoteExecutor.Program.Main(System.String[])

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW[[Interop+ComCtl32+LVGROUPW, System.Windows.Forms.Primitives, Version=42.42.42.42, Culture=neutral, PublicKeyToken=b77a5c561934e089]](IntPtr, WM, IntPtr, LVGROUPW ByRef)
   at System.Windows.Forms.Tests.ListViewGroupTests+<>c.<ListView_FooterAlignment_GetGroupInfo_Success>b__16_0(System.String, System.String, System.String)
   at System.RuntimeMethodHandle.InvokeMethod(System.Object, System.Object[], System.Signature, Boolean, Boolean)
   at System.Reflection.RuntimeMethodInfo.Invoke(System.Object, System.Reflection.BindingFlags, System.Reflection.Binder, System.Object[], System.Globalization.CultureInfo)
   at System.Reflection.MethodBase.Invoke(System.Object, System.Object[])
   at Microsoft.DotNet.RemoteExecutor.Program.Main(System.String[])

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW[[Interop+ComCtl32+LVGROUPW, System.Windows.Forms.Primitives, Version=42.42.42.42, Culture=neutral, PublicKeyToken=b77a5c561934e089]](IntPtr, WM, IntPtr, LVGROUPW ByRef)
   at System.Windows.Forms.Tests.ListViewGroupTests+<>c.<ListView_FooterAlignment_GetGroupInfo_Success>b__16_0(System.String, System.String, System.String)
   at System.RuntimeMethodHandle.InvokeMethod(System.Object, System.Object[], System.Signature, Boolean, Boolean)
   at System.Reflection.RuntimeMethodInfo.Invoke(System.Object, System.Reflection.BindingFlags, System.Reflection.Binder, System.Object[], System.Globalization.CultureInfo)
   at System.Reflection.MethodBase.Invoke(System.Object, System.Object[])
   at Microsoft.DotNet.RemoteExecutor.Program.Main(System.String[])

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW[[Interop+ComCtl32+LVGROUPW, System.Windows.Forms.Primitives, Version=42.42.42.42, Culture=neutral, PublicKeyToken=b77a5c561934e089]](IntPtr, WM, IntPtr, LVGROUPW ByRef)
   at System.Windows.Forms.Tests.ListViewGroupTests+<>c.<ListView_FooterAlignment_GetGroupInfo_Success>b__16_0(System.String, System.String, System.String)
   at System.RuntimeMethodHandle.InvokeMethod(System.Object, System.Object[], System.Signature, Boolean, Boolean)
   at System.Reflection.RuntimeMethodInfo.Invoke(System.Object, System.Reflection.BindingFlags, System.Reflection.Binder, System.Object[], System.Globalization.CultureInfo)
   at System.Reflection.MethodBase.Invoke(System.Object, System.Object[])
   at Microsoft.DotNet.RemoteExecutor.Program.Main(System.String[])

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.CallWindowProcW(IntPtr, IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.DefWndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at Interop+User32.SendMessageW(IntPtr, WM, IntPtr, IntPtr)
   at System.Windows.Forms.Tests.ListViewTests+<>c.<ListView_Handle_GetWithGroups_Success>b__62_0()
   at System.RuntimeMethodHandle.InvokeMethod(System.Object, System.Object[], System.Signature, Boolean, Boolean)
   at System.Reflection.RuntimeMethodInfo.Invoke(System.Object, System.Reflection.BindingFlags, System.Reflection.Binder, System.Object[], System.Globalization.CultureInfo)
   at System.Reflection.MethodBase.Invoke(System.Object, System.Object[])
   at Microsoft.DotNet.RemoteExecutor.Program.Main(System.String[])

M-Lipin pushed a commit to M-Lipin/winforms that referenced this pull request Mar 23, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Feb 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for footers to ListViewGroup

2 participants