Port TableLayoutPanelDesigner, TabControlDesigner to runtime#9560
Conversation
| // The .NET Foundation licenses this file to you under the MIT license. | ||
| // See the LICENSE file in the project root for more information. | ||
|
|
||
| #nullable disable |
There was a problem hiding this comment.
Maybe we can enable nullability in the designer direcly, as the PR https://github.com/dotnet/winforms/pull/9408/files does
There was a problem hiding this comment.
There are too many changes, first migrate the API, and then update them.
There was a problem hiding this comment.
Yes, please keep migration changes separate from the nullability ones and create a second follow up PR
|
@SimonZhao888 - did you copy this over from the VS repo? |
Tanya-Solyanik
left a comment
There was a problem hiding this comment.
Looks good, but please address the test failures and follow up on nullability and other clean-up comments in the next PR.
src/System.Windows.Forms.Primitives/src/System/Windows/Forms/Internals/ClientUtils.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/TableLayoutPanelDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/TableLayoutPanelDesigner.cs
Outdated
Show resolved
Hide resolved
| { | ||
| get | ||
| { | ||
| return bounds; |
There was a problem hiding this comment.
Please use expression-bodied properties, this could be done in the next PR or in a separate commit. Then we would have to merge this PR using a merge-commit rather than a squash to preserve history.
...em.Windows.Forms.Design/src/System/Windows/Forms/Design/Behavior/TableLayoutPanelBehavior.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Primitives/src/System/Windows/Forms/Internals/ClientUtils.cs
Outdated
Show resolved
Hide resolved
...em.Windows.Forms.Design/src/System/Windows/Forms/Design/Behavior/TableLayoutPanelBehavior.cs
Outdated
Show resolved
Hide resolved
...em.Windows.Forms.Design/src/System/Windows/Forms/Design/Behavior/TableLayoutPanelBehavior.cs
Outdated
Show resolved
Hide resolved
Yes, it's copy from VS repo. |
dmitrii-drobotov
left a comment
There was a problem hiding this comment.
Looks good! @SimonZhao888 - as a follow-up, we can also port StyleCollectionEditor which will be opened on "Edit Rows and Columns" button in TableLayoutPanelDesigner.
src/System.Windows.Forms/tests/IntegrationTests/DesignSurface/DemoConsole/MainForm.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/TableLayoutPanelDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Primitives/src/System/Windows/Forms/Internals/ClientUtils.cs
Outdated
Show resolved
Hide resolved
...em.Windows.Forms.Design/src/System/Windows/Forms/Design/Behavior/TableLayoutPanelBehavior.cs
Show resolved
Hide resolved
...Windows.Forms.Design/src/System/Windows/Forms/Design/Behavior/TableLayoutPanelResizeGlyph.cs
Outdated
Show resolved
Hide resolved
Tanya-Solyanik
left a comment
There was a problem hiding this comment.
Looks good, I'd let Devendar comment if we should remove bug references or not.
6ffe728
| @@ -0,0 +1,50 @@ | |||
| using System.ComponentModel.Design; | |||
There was a problem hiding this comment.
The license header is missing here

Fixes #8790
Proposed changes
Customer Impact
Regression?
Risk
Screenshots
Before
TabellayoutPanelDesigner, TabControlDesigner can not be designed test app.

After
TabellayoutPanelDesigner, TabControlDesigner can be designed in runtime.

Test methodology
Accessibility testing
Test environment(s)
Microsoft Reviewers: Open in CodeFlow